[PHP] Re: File upload

2001-10-31 Thread Liz Fulghum
use unlink() to remove the temporary file. http://www.php.net/manual/en/features.file-upload.php contains a whole bunch of information on the topic that may be useful -- Liz Fulghum -- http://www.lipstickalley.com/ - Be Popular! Want to

[PHP] Re: $ENV{'REMOTE_ADDR'}

2001-10-31 Thread Liz Fulghum
if ($REMOTE_ADDR=="127.0.0.1") { do something } elseif ($REMOTE_ADDR=="remote.somewhere.com") { do something else } else { eeks! its the end } List of all the predefined variables: http://www.php.net/manual/en/language.variables.predefined

Re: Re[2]: [PHP] split array in 2 halfs

2001-10-31 Thread Liz Fulghum
You could also grab the midpoint of the array: $count = round(count($array), 0); then populate your new arrays by using a foreach loop: $x = 0; foreach($array as $key => $value) { if ($x <=$count) { $array1[] = $value; } else { $array2[] = $value; } $x++; } "D

Re: Re[2]: [PHP] split array in 2 halfs

2001-10-31 Thread Liz Fulghum
Correction: $count = count($array); $count = $count/2; $count = round($count,0); "Liz Fulghum" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > You could also grab the midpoint of the array: > > $count = round(count($array

[PHP] Re: Help with an error I can't find!

2001-11-01 Thread Liz Fulghum
Sounds like $HTTP_POST_VARS is not a valid array (to check do if(is_array($HTTP_POST_VARS)) { print "YUP"; } else { print "NOPE"; }) Check to make sure that track_vars is turned on in the PHP.ini. "Lic. Carlos A. Triana Torres" <[EMAIL PROTECTED]> wrote in message 005901c16324$1cf252e0$0301a8c0

[PHP] Re: simple array tutorial wanted

2001-11-01 Thread Liz Fulghum
http://www.onlamp.com/pub/a/php/2001/06/07/php_foundations.html "Justin French" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi all, > > I really want to get me head around arrays, becuase > I KNOW there's a better way to do some of the stuff > i'm doing

[PHP] Re: Deleting Array elements

2001-11-02 Thread Liz Fulghum
One idea is to read the file into an array, use substr to match the existance of the user to be deleted, and if the user isn't to be deleted, read the line into a new array, then write the new file to the array. "Hew Staff" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTE

Re: Re[2]: [PHP] Passing many valaues to function

2001-11-03 Thread Liz Fulghum
which is line 235? "Daniel Harik" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I have following code > > class Member{ > >function vallidateForm ($HTTP_POST_VARS){ > echo "$HTTP_POST_VARS['frmUsername']"; >} > > } > $user = new Member; > if($ac