php-general Digest 21 Jan 2001 17:48:15 -0000 Issue 468 Topics (messages 35881 through 35908): Re: " " charactor problem 35881 by: Sean Cazzell 35893 by: Rick Ridgeway 35902 by: CC Zona imap_createmailbox 35882 by: Jochen Kächelin Re: Sending a mail in HTML format 35883 by: Kristi Russell Re: Cookies... 35884 by: Kristi Russell Re: problem listing directory contents 35885 by: Vahan Yerkanian Why won`t this work?? 35886 by: Website4S.aol.com 35887 by: bard 35889 by: Alexander Wagner 35891 by: bard 35892 by: Alexander Wagner Re: my cookies arent working! 35888 by: Markus Fischer 35890 by: Lucas Young Upgrading to 4.04 question, but won't stick 35894 by: Team JUMP Lists 35908 by: webbie.server.deanox.com MySQL replication 35895 by: Andi Gutmans 35907 by: Sean Cazzell GetImageSize problem 35896 by: Sue Bailey 35898 by: Romulo Roberto Pereira 35899 by: Sue Bailey 35901 by: Romulo Roberto Pereira file selected in form changes in next php page?! 35897 by: Chris Hayes Re: ibase_num_fields() -a workaround ? 35900 by: Meir Kriheli - MKsoft Build with Apache on Linux 35903 by: Chris Mulcahy Help With passthru, system, exec 35904 by: Pete Lavetsky Looking for a web host provider 35905 by: Pascal Clerin 35906 by: Kristi Russell Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] ----------------------------------------------------------------------
> I grab this line and try to make it an array like this: print "line: $thelinefromfile\n"; //Check the line > $var1 = trim($thelinefromfile); > $var2 = split(" ", $thelinefromfile); > $count = count($var2); Are you sure $thelinefromfile is actually being set correctly? Regards, Sean
Sean Cazzell wrote: > > I grab this line and try to make it an array like this: > print "line: $thelinefromfile\n"; //Check the line > > $var1 = trim($thelinefromfile); > > $var2 = split(" ", $thelinefromfile); > > $count = count($var2); > > Are you sure $thelinefromfile is actually being set correctly? > > Regards, > > Sean Yes I print it out it says "Array" so i then do print $thelinefromfile[0]; and it prints out the whole line instead of the first field from the line... -- Rick Ridgeway
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Rick Ridgeway) wrote: > > > I grab this line and try to make it an array like this: > > print "line: $thelinefromfile\n"; //Check the line > > > $var1 = trim($thelinefromfile); > > > $var2 = split(" ", $thelinefromfile); > > > $count = count($var2); > > > > Are you sure $thelinefromfile is actually being set correctly? > > > > Regards, > > > > Sean > > Yes > I print it out it says "Array" > so i then do > print $thelinefromfile[0]; > and it prints out the whole line instead of the first field from the > line... You're print()ing in the order shown above, right? Print() then trim() then split()? Because that sounds like you're attempting to do a "split()" on an array. That function is for turning a string into an array; if it's already an array, then just get rid of the split() and do your count() on $thelinefromfile. -- CC
i have the following problem: i have the possibility to create 100 different pop-boxes and 100 different email-addresses. the pop-boxes must have the following name: wpXXXX-jk, wpXXXX-info and so on where XXXX stands for my custumer number an the text after the '-' for the part of the email-address before the '@'. when I want to catch all email for [EMAIL PROTECTED] I need the following: host: mail.domain.de username: wpXXXX-jk passwort: ********** When I will create a new pop-box and a new email-adress I use $link=imap_open($MAILSERVER,$username, $passwort, OP_HALFOPEN); $test = imap_createmailbox ($link,imap_utf7_encode ("{$MAILSERVER}INBOX.$newname")); But how can I set the passwort for the new created pop-box? Please help me. THANXS! -- ********************************************** * Jochen Kächelin * * Ihr WEBberater - Werbeagentur Pulvermüller * * Stuttgarter Str. 3 - D-73033 Göppingen * * www.wa-p.de - mailto:[EMAIL PROTECTED] * **********************************************
Nothing special, just add <html> at the beginning of what you're trying to send as HTML. Always worked for me? Kristi ----- Original Message ----- From: "Pascal Clerin" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, January 20, 2001 8:46 PM Subject: [PHP] Sending a mail in HTML format > Hello, > > I want to send a mail in HTML format with the mail() function. > I have tried to send html stuff in the message parameter, but when I read it > in my hotmail account, I just see the html code and not what the html is > supposed to show. > I suppose that it is necessary to send some additional headers to specify that > the mail is in html format. > Thanks for your help. > > Pascal > > ____________________________________________________________________ > Get free email and a permanent address at http://www.netaddress.com/?N=1 > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] >
time()+86400? ----- Original Message ----- From: "WreckRman2" <[EMAIL PROTECTED]> To: "'Php-General@Lists. Php. Net'" <[EMAIL PROTECTED]> Sent: Saturday, January 20, 2001 4:56 PM Subject: [PHP] Cookies... > > Currently my cookie expires in 1 hour, How can I make it expire in 1 day? > > setcookie("MemberLogin",$value,time()+3600); /* expire in 1 hour */ > setcookie("MemberLogin",$value,time()+3600,"/",".combatfs.com",1); > > WreckRman2 > Combat Flight Center > http://www.combatfs.com > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] >
Greetings All! Recently I've been hit by a strange problem while coding a file indexing system. I have a source directory of the following format: /files/0-9 /files/0-9/0-90 /files/0-9/0-91 /files/a /files/a/a0 /files/a/a1 /files/b ... /file/z ok you got the picture I hope. nothing difficult. now when i try to exec my script, it hangs somewhere at path /files/a/a2 halting right before it should switch to b0... I'm including kinda long script below hoping some kind soul could examine it and throw the errors i've made into my face. I HOPE THIS IS NOT A BUG IN PHP. <? function dir_list($dirname) { $handle=opendir($dirname); while (($file = readdir($handle))!==false) { if($file=='.'||$file=='..') continue; $result_array[]=$dirname.$file; } closedir($handle); return $result_array; }; ######################################################################## $HTMLDir="/WWW/htdocs/listss/"; $FileDir="/WWW/files/"; echo "<B><FONT FACE=verdana,arial,helvetica SIZE=-2>\n"; #Reset and Start the Timer. $updated=0; $added=0; $removed=0; $total=0; $starttime = doubleval(ereg_replace('^0\.([0-9]*) ([0-9]*)$','\\2.\\1',microtime())); #Get Contents of main directory. $D1=dir_list($FileDir); #Cycle Through each subdir of $FileDir. $S1=sizeof($D1); for ($i1=0; $i1<$S1; $i1++) { #Check whether the current item is not a directory, report and die if it is a file. if (!is_dir($D1[$i1])) die("<FONT COLOR=#660000>ERROR 01:</FONT> $D1[$i1] is a file, should be moved to a subdirectory.<BR>\n"); #CD into the current subdir. $SubDir="$D1[$i1]/"; chdir($SubDir); #Get contents of the current subdir. $D2=dir_list($SubDir); #Keep the name of current subdir in $CL $CL=substr($D1[$i1],strrpos($D1[$i1],'/')+1); #Print the header for the current directory. echo "<BR><FONT SIZE=+1>"; if ($CL!="nm") echo strtoupper($CL); else echo "Numbers & Symbols"; echo"</FONT><BR><HR NOSHADE SIZE=0 ALIGN=LEFT WIDTH=500>\n"; $S2=sizeof($D2); for ($i2=0; $i2<$S2; $i2++) { #CD into the current subsubdir. $SubSubDir="$D2[$i2]/"; echo "Entering $SubSubDir<BR>\n"; chdir($SubSubDir); #Generate current HTML filename. $CFL=substr($D2[$i2],strrpos($D2[$i2],'/')+1); if (ereg("nm",$CFL)) $CFL=ereg_replace("nm","0-9",$CFL); if (ereg("0-90",$CFL)) $CFL=ereg_replace("0-90","0-9",$CFL); if ($CFL[1]=='0') $CFL=ereg_replace("0","",$CFL); $CF="$HTMLDir$CFL.html"; #Open current HTML file. echo " Writing to File $CF<BR>\n"; $fp=fopen($CF,'w'); #Get contents of the current subdir. $D3=dir_list($SubSubDir); $S3=sizeof($D3); for ($j=0; $j<$S3; $j++) { echo "$D3[$j]<BR>\n"; }; #Close current HTML file. echo " Closing File $CF<BR>\n"; fclose($fp); #Return one level back,subletter listing. echo "Returning to $SubDir<BR><BR>\n"; #chdir($SubDir); }; #Return one level back, letter listing. #chdir($FileDir); }; #Get the finish time and printout the stats. $endtime = doubleval(ereg_replace('^0\.([0-9]*) ([0-9]*)$','\\2.\\1',microtime())); echo "<BR><BR><BR><FONT SIZE=+1>STATISTICS</FONT><BR><HR NOSHADE ALIGN=LEFT SIZE=0 WIDTH=500>\n"; echo "Time Spent: <FONT COLOR=#660000>"; echo $endtime - $starttime; echo "</FONT> sec<BR>\n"; echo "<BR><BR><BR><BR>"; ?> Thanks in advance -- Vahan Yerkanian Email: [EMAIL PROTECTED] Leading Web Developer / Designer Phone: (374) 158-2723 Web Development Department Fax: (374) 128-5082 ARMINCO Global Telecommunications http://www.arminco.com
Hi, Can anyone tell me before I rip my hair out, why this won`t work?? if (!UN) { printf("<SCRIPT LANGUAGE='JAVASCRIPT'>alert('Please enter a User Name.');self.history.back();</SCRIPT>"); } TIA Ade
Try this... <?php if (!$UN) { ?> <SCRIPT LANGUAGE=JAVASCRIPT> alert('Please enter a User Name.'); self.history.back(); </SCRIPT> <? } ?> Cheers, Brad On Sun, 21 Jan 2001 [EMAIL PROTECTED] wrote: > Hi, > > Can anyone tell me before I rip my hair out, why this won`t work?? > > if (!UN) > { > printf("<SCRIPT LANGUAGE='JAVASCRIPT'>alert('Please enter a User > Name.');self.history.back();</SCRIPT>"); > } > > TIA > Ade > >
[EMAIL PROTECTED] wrote: > Hi, > > Can anyone tell me before I rip my hair out, why this won`t work?? > > if (!UN) > { > printf("<SCRIPT LANGUAGE='JAVASCRIPT'>alert('Please enter a User > Name.');self.history.back();</SCRIPT>"); > } > > TIA > Ade An undefined constant will return true. You have to explicitly define it as 0 to make this work. I guess this is becauese PHP interpretes it as a string, and all strings but '' are true. It has to, because it doesn't know it is a constant. Wagner -- Three may keep a secret, if two of them are dead.
On Sun, 21 Jan 2001, Alexander Wagner wrote: > [EMAIL PROTECTED] wrote: > > Hi, > > > > Can anyone tell me before I rip my hair out, why this won`t work?? > > > > if (!UN) > > { > > printf("<SCRIPT LANGUAGE='JAVASCRIPT'>alert('Please enter a User > > Name.');self.history.back();</SCRIPT>"); > > } > > > > TIA > > Ade > > An undefined constant will return true. You have to explicitly define > it as 0 to make this work. > I guess this is becauese PHP interpretes it as a string, and all > strings but '' are true. It has to, because it doesn't know it is a > constant. > > Wagner > Plus, this is PHP, not javascript. Variables look like this, "$UN" not this, "UN". Brad
bard wrote: > Plus, this is PHP, not javascript. Variables look like this, "$UN" > not this, "UN". $UN is a variable. UN might be a constant, if it is defined as one. If not, its just a string. Wagner -- Three may keep a secret, if two of them are dead.
On Sun, Jan 21, 2001 at 05:45:44PM +1300, Lucas Young wrote : > I'm actually using code from the web - sympoll from www.ralusp.net and > authlib, both give me errors and neither seems to be writing cookies... I > note in PHP the session save path is /tmp, where should this folder live? Where you think its best secure. Or no files at all and sessions saved to database (with session_handlers). But, what about cookies ? Session file layout has nothing to do make cookies work or not. m. -- Markus Fischer, http://josefine.ben.tuwien.ac.at/~mfischer/ EMail: [EMAIL PROTECTED] PGP Public Key: http://josefine.ben.tuwien.ac.at/~mfischer/C2272BD0.asc PGP Fingerprint: D3B0 DD4F E12B F911 3CE1 C2B5 D674 B445 C227 2BD0
Hmmm, ok, so what else could I be missing that is stopping my cookies working? -----Original Message----- From: Markus Fischer [mailto:[EMAIL PROTECTED]] Sent: Sunday, 21 January 2001 10:31 p.m. To: Php-General Subject: Re: [PHP] my cookies arent working! On Sun, Jan 21, 2001 at 05:45:44PM +1300, Lucas Young wrote : > I'm actually using code from the web - sympoll from www.ralusp.net and > authlib, both give me errors and neither seems to be writing cookies... I > note in PHP the session save path is /tmp, where should this folder live? Where you think its best secure. Or no files at all and sessions saved to database (with session_handlers). But, what about cookies ? Session file layout has nothing to do make cookies work or not. m. -- Markus Fischer, http://josefine.ben.tuwien.ac.at/~mfischer/ EMail: [EMAIL PROTECTED] PGP Public Key: http://josefine.ben.tuwien.ac.at/~mfischer/C2272BD0.asc PGP Fingerprint: D3B0 DD4F E12B F911 3CE1 C2B5 D674 B445 C227 2BD0 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
We've had 4.01 running since July so I thought I'd upgrade to 4.04 from the tarball last night. Everything went fine w/ the compile, no errors. Install said all OK, Then i went and HUP'd apache but when I run phpinfo() the old module is still loaded. What am I doing wrong? Where should I look to solve my problem. When I look in the /modules/ directory the dates on the new modules are yesterday, so they've all moved correctly, etc. I intentionally tried to break the phpmodule to see which one I'm actually using by changing the name of the file but that didn't work. Linux 6.2, Apache 1.3.12., MySQL, PHP 4.01 Any help appreciated. If someone can just point me to an RPM that'll install on RH 6.2, I'll just use that. The current RPM's over at RH won't install because they are for RH 7. TIA, Charlie
Quoting Team JUMP Lists <[EMAIL PROTECTED]>: > We've had 4.01 running since July so I thought I'd upgrade to 4.04 from > the > tarball last night. Everything went fine w/ the compile, no errors. > Install > said all OK, Then i went and HUP'd apache but when I run phpinfo() the > old > module is still loaded. > > What am I doing wrong? Where should I look to solve my problem. When I > look > in the /modules/ directory the dates on the new modules are yesterday, > so > they've all moved correctly, etc. I intentionally tried to break the > phpmodule to see which one I'm actually using by changing the name of > the > file but that didn't work. > > Linux 6.2, Apache 1.3.12., MySQL, PHP 4.01 > > Any help appreciated. If someone can just point me to an RPM that'll > install > on RH 6.2, I'll just use that. The current RPM's over at RH won't > install > because they are for RH 7. Well, it's my opinion that on an RPM-package based system it is wise to do custom package installations via RPM also - so that you don't break the RPM dependency checking. It's not that hard to grab the PHP4 SRPM from RedHat's Rawhide stash, install it, replace the tarball with the latest from php.net, and then build the RPM and then install it. It's a bit of extra work, but it keeps RPM functioning properly. If you need things like pdflib, it's not that hard to create the spec file and build it, too. Lee Howard
Hey, Have any of you guys worked with the latest and greatest MySQL replication? Does it work? What are its ups and downs? Andi
Andi, No personal experience (yet), but there's a good article on phpbuilder that you might want to take a look at if you haven't already: http://www.phpbuilder.com/columns/tanoviceanu20000912.php3 Regards, Sean
I have a bunch of images living on one ISP's server which I want to use on another page on another ISP's server, with GetImageSize. I RTFM, and see "The filename needs to be either relative to the current document, or an absolute filesystem path. Thus absolute URL paths will not work." which is absolutely correct - I get an error msg "cannot open file". $DOCUMENT_ROOT is obviously no use to me - does anyone know any way round this? TIA, Sue
Hello! First - some ISP block you from get files from their server by a httpd request (that is what php does... I think!). To be sure if this is set or not, in the other ISP (not the one that the images are) write a simple html like this: <html><head><title>loading images between servers</title></head><body> <br><br> <img src="http://Domain/ImagesDir/ImagesName.gif"> </body></html> In "http://Domain/ImagesDir/ImagesName.gif" be sure to put the correct domain and location of the image. This should show the image... If not you could have two problems: the link is wrong or the filter is set. Imagine this - I have a web site in an ISP with my domain like: http://www.mydomain.com and all the paths are gting the images from a free server like geocities.com so I don;t expend money on buying large amounts of bandwith for my site... If you think this way you know why they do that. if this works, just use thi path "http://Domain/ImagesDir/ImagesName.gif" in all your scripts for getimagesize... I expect that this helps. Rom
Thanks Rom - I can get the pics with an img src tag, which is why I assumed that GetImageSize would also work - but now I'm told it only works on the local machine, so I guess I'll have to live with text jumping about while pics download. :( Romulo Roberto Pereira wrote: > > Hello! > > First - some ISP block you from get files from their server by a httpd > request (that is what php does... I think!). To be sure if this is set or > not, in the other ISP (not the one that the images are) write a simple html > like this: > > <html><head><title>loading images between servers</title></head><body> > <br><br> > <img src="http://Domain/ImagesDir/ImagesName.gif"> > </body></html> > > In "http://Domain/ImagesDir/ImagesName.gif" be sure to put the correct > domain and location of the image. > > This should show the image... If not you could have two problems: the link > is wrong or the filter is set. > > Imagine this - I have a web site in an ISP with my domain like: > http://www.mydomain.com and all the paths are gting the images from a free > server like geocities.com so I don;t expend money on buying large amounts of > bandwith for my site... If you think this way you know why they do that. > > if this works, just use thi path "http://Domain/ImagesDir/ImagesName.gif" in > all your scripts for getimagesize... > > I expect that this helps. > > Rom > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED]
If you reaaaaaaaally don't like the text jumping you can do a little script that can parse the width and height for each image, I mean get this info from the html files... But you will have to pin point each one... The good thing that the script is here... <? ################################################# ## GetURLImageSize( $urlpic ) determines the ## dimensions of local/remote URL pictures. ## returns array with ( $width,$height,$type ) ## ## Thanks to: Oyvind Hallsteinsen aka Gosub / ELq - [EMAIL PROTECTED] ## for the original size determining code ## ## PHP Hack by Filipe Laborde-Basto Oct 21/2000 ## FREELY DISTRIBUTABLE -- use at your sole discretion! :) Enjoy. ## (Not to be sold in commercial packages though, keep it free!) ## Feel free to contact me at [EMAIL PROTECTED] (http://www.rezox.com) ################################################# define(GIF_SIG, "\x47\x49\x46"); define(JPG_SIG, "\xff\xd8\xff"); define(PNG_SIG, "\x89\x50\x4e\x47\x0d\x0a\x1a\x0a"); define(JPG_SOF0, "\xc0"); /* Start Of Frame N */ define(JPG_SOF1, "\xc1"); /* N indicates which compression process */ define(JPG_SOF2, "\xc2"); /* Only SOF0-SOF2 are now in common use */ define(JPG_SOF3, "\xc3"); define(JPG_SOF5, "\xc5"); /* NB: codes C4 and CC are NOT SOF markers */ define(JPG_SOF6, "\xc6"); define(JPG_SOF7, "\xc7"); define(JPG_SOF9, "\xc9"); define(JPG_SOF10, "\xca"); define(JPG_SOF11, "\xcb"); define(JPG_SOF13, "\xcd"); define(JPG_SOF14, "\xce"); define(JPG_SOF15, "\xcf"); define(JPG_EOI, "\xd9"); /* End Of Image (end of datastream) */ define(JPG_SOS, "\xda"); /* Start Of Scan - image data start */ define(RD_BUF, 512); /* amount of data to initially read */ function GetURLImageSize( $urlpic $fd= @fopen($urlpic,"r"); fd){ #read in 1k, enough for GIF,PNG. #continue to read from file, if the JPG chunk exceeds this $imgData = fread( $fd,RD_BUF ); if( substr($imgData,0,3)==GIF_SIG $dim =unpack ("v2dim",substr($imgData,6,4) ); $width=$dim["dim1"]; $height=$dim["dim2"]; $type = 1; } elseif( substr($imgData,0,8)==PNG_SIG $dim =unpack ("N2dim",substr($imgData,16,8) ); $width=$dim["dim1"]; $height=$dim["dim2"]; $type = 3; } elseif( substr($imgData,0,3)==JPG_SIG ################# JPG CHUNK SCAN #################### $imgPos = 2; $type = 2; $buffer = RD_BUF-2; while($imgPos < strlen($imgData)) /* synchronize to the marker 0xFF */ $imgPos=strpos(&$imgData,0xFF,$imgPos)+1; $marker = $imgData[$imgPos]; do { $marker = ord($imgData[$imgPos++]); } while ($marker == 255); /* find dimensions of block */ switch (chr($marker)) /* Grab width/height from SOF segment (these are acceptable chunk types) */ case JPG_SOF0: case JPG_SOF1: case JPG_SOF2: case JPG_SOF3: case JPG_SOF5: case JPG_SOF6: case JPG_SOF7: case JPG_SOF9: case JPG_SOF10: case JPG_SOF11: case JPG_SOF12: case JPG_SOF13: case JPG_SOF14: case JPG_SOF15: $dim =unpack ("n2dim",substr($imgData,$imgPos+3,4) ); $height=$dim["dim1"]; $width=$dim["dim2"]; break 2; file://found it so exit case JPG_EOI: case JPG_SOS: return FALSE; /* End loop in case we find one of these markers */ default: /* We're not interested in other markers */ $skiplen = (ord($imgData[$imgPos++])<<8)+ord($imgData[$imgPos++])-2; /* if the skip is more than what we've read in, read more */ $buffer -= $skiplen; if( $buffer<512 ){ #if the buffer of data is too low,read more file. $imgData .= fread( $fd,$skiplen+1024 ); $buffer += $skiplen+1024; }; $imgPos += $skiplen; break; }; file://endif check marker type }; file://endif loop through JPG chunks }; file://endif chk for valid file types # got the pic dimensions, close the file fclose ($fd); return array( $width,$height,$type ); } else return array( '','','' ); }; file://endif valid file pointer chk }; // end function ?> Rom ----- Original Message ----- From: Sue Bailey <[EMAIL PROTECTED]> To: Romulo Roberto Pereira <[EMAIL PROTECTED]> Cc: php-general <[EMAIL PROTECTED]> Sent: Sunday, January 21, 2001 10:35 AM Subject: Re: [PHP] GetImageSize problem Thanks Rom - I can get the pics with an img src tag, which is why I assumed that GetImageSize would also work - but now I'm told it only works on the local machine, so I guess I'll have to live with text jumping about while pics download. :( Romulo Roberto Pereira wrote: > > Hello! > > First - some ISP block you from get files from their server by a httpd > request (that is what php does... I think!). To be sure if this is set or > not, in the other ISP (not the one that the images are) write a simple html > like this: > > <html><head><title>loading images between servers</title></head><body> > <br><br> > <img src="http://Domain/ImagesDir/ImagesName.gif"> > </body></html> > > In "http://Domain/ImagesDir/ImagesName.gif" be sure to put the correct > domain and location of the image. > > This should show the image... If not you could have two problems: the link > is wrong or the filter is set. > > Imagine this - I have a web site in an ISP with my domain like: > http://www.mydomain.com and all the paths are gting the images from a free > server like geocities.com so I don;t expend money on buying large amounts of > bandwith for my site... If you think this way you know why they do that. > > if this works, just use thi path "http://Domain/ImagesDir/ImagesName.gif" in > all your scripts for getimagesize... > > I expect that this helps. > > Rom > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED]
Dear group, in my first page i have a form selcting a file. The names i used were csvfile, csv_file, and my_file. After submitting the form the filename changed to a totally different file, like C:\PHP\php72C3.TMP or C:\PHP\phpD2B4.TMP (windows, apache, php4, internet explorer 5 as well as Mozilla 6) What is happening? code below. Chris ##FORM <form name="form1" enctype="multipart/form-data" method="post" ACTION=<?php echo "$PHP_SELF";?> NAME="beheerform"> <input type="hidden" name="FILE_INVOEREN" value="zoek file (op eigen computer)"> <input type="file" name="my_file" onChange='javascript:alert(this.value);'> <input type="submit" name="Submit" value="Invoeren"> </form> ## NEXT PAGE (in main) if (isset($FILE_INVOEREN)): echo $my_file; if ($my_file==0) die ("Selecteer een file!"); -------------------------------------------------------------------- -- C.Hayes Droevendaal 35 6708 PB Wageningen the Netherlands -- --------------------------------------------------------------------
Hi ibase_num_fields returns the column count of the result, not the row count ! Meir Kriheli MKsoft computer systems 'There's someone in my head but it's not me" - Pink Floyd ----- Original Message ----- From: <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, January 20, 2001 7:01 AM Subject: [PHP] ibase_num_fields() -a workaround ? > ibase_num_fields() isn't functional in php 4 - anyone have any ideas to > work around this ? > > I'm checking the number of results for a query to check if a > user/password is correct -I suppose I could just do a fetch_row() on the > result and test if thats empty or not - but I'll only do that as a last > resort
OK, I've built Apache and PHP on Linux 50 times already. Now it's causing me problems. I've rebuilt my server, I've tried PHP 4.0.3 and PHP 4.0.4. It keeps causing me problems. I could not find libphp4.a and found on the net where someone suggested to rename libmodphp4.a to libphp4.a. During configure, I'm getting an error: /usr/bin/ld: cannot find -lmodphp4 collect2: ld returned 1 exit status It's making me insane. Attached below is a complete transcript (it's small) of the apache configure. PHP configure; make; make install appears to work perfectly, but it's not going so well with Apache. Any suggestions greatly appreciated. Thanks in advance. Chris ---> BEGIN Transcript <--- [root@gumby apache_1.3.14]# ./configure --activate-module=src/modules/php4/libphp4.a Configuring for Apache, Version 1.3.14 make + using installation path layout: Apache (config.layout) + activated php4 module (modules/php4/libphp4.a) Creating Makefile Creating Configuration.apaci in src cd ..; gcc -DLINUX=2 -I/home/cmulcahy/transfer/php-4.0.3pl1 -I/home/cmulcahy/trans fer/php-4.0.3pl1/main -I/home/cmulcahy/transfer/php-4.0.3pl1/main -I/home/cm ulcahy/transfer/php-4.0.3pl1/Zend -I/home/cmulcahy/transfer/php-4.0.3pl1/Zen d -I/home/cmulcahy/transfer/php-4.0.3pl1/TSRM -I/home/cmulcahy/transfer/php- 4.0.3pl1/TSRM -I/home/cmulcahy/transfer/php-4.0.3pl1 -DUSE_EXPAT -I./lib/exp at-lite -DNO_DL_NEEDED `./apaci` -o helpers/dummy lpers/dummy.c -rdynamic -Lmodules/php4 -L../modules/php4 -L../../modules/p hp4 -lmodphp4 -lpam -ldl -lttf -lgd -lresolv -lm -ldl -lcrypt -lnsl -lres olv -lm -lcrypt /usr/bin/ld: cannot find -lmodphp4 collect2: ld returned 1 exit status make: *** [dummy] Error 1 Creating Makefile in src + configured for Linux platform + setting C compiler to gcc + setting C pre-processor to gcc -E + checking for system header files + adding selected modules o php4_module uses ConfigStart/End + checking sizeof various data types + doing sanity check on compiler and options ** A test compilation with your Makefile configuration ** failed. The below error output from the compilation ** test will give you an idea what is failing. Note that ** Apache requires an ANSI C Compiler, such as gcc. ======== Error Output for sanity check ======== ============= End of Error Report ============= Aborting!
Hi Everyone, I've been trying to write something to ping a URL on the system level, and keep the output in an array. I've been trying to work with system, exec, and passthru, but it looks as though they all return only the last line of the output. How would I put the whole output into the array? A different function, or possible it was with backtics, though I couldn't find any examples that did this. Any help would be appreciated. if($IP) { $systemstring=escapeshellcmd("ping $IP -c 1"); $array = passthru("$systemstring",$returnvalue); echo $array; --> This outputs only the last line } Thanks, Pete
Hello I am bored with my web host provider (www.linuwebhost.com) because it becomes unreachable several times a month (since 5 this morning I am not able to access my site...). In fact I need a good web host provider where I can host my site, with PHP(3 or 4), MySQL, 50MB, and more features as mail, php modules etc... that can support 300 users a day accessing a site with a lot of MySQL requests (I doubt that a server that hosts 250 domains and has 512 MB will serve me, or not?). Suppose that it could be possible to find that for good price (what is a good price?). Thanks for any suggestions. Pascal -- _______________________________________________ Get your free email from http://www.graffiti.net
Check out www.webintellects.com. To date, I haven't had any problems and the service is $18.95 a month. 200MB of diskspace, 50 user accounts, PHP4, MySQL, domain name hosting, etc. Kristi ----- Original Message ----- From: "Pascal Clerin" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, January 21, 2001 12:15 PM Subject: [PHP] Looking for a web host provider > Hello > > I am bored with my web host provider (www.linuwebhost.com) because it becomes unreachable several times a month (since 5 this morning I am not able to access my site...). > In fact I need a good web host provider where I can host my site, with PHP(3 or 4), MySQL, 50MB, and more features as mail, php modules etc... that can support 300 users a day accessing a site with a lot of MySQL requests (I doubt that a server that hosts 250 domains and has 512 MB will serve me, or not?). > > Suppose that it could be possible to find that for good price (what is a good price?). > > Thanks for any suggestions. > > Pascal > -- > _______________________________________________ > Get your free email from http://www.graffiti.net > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] >