|
|
 |
Re: FN-FORUM: This is driving me mad
date posted 2nd August 2005 19:31
Assuming that $p is a path and $i_name is the (image by any chance?)
name you want to copy to, then I would think that the most likely
cause of the error is that $p is defined but $i_name is not. This
would cause the file to copy to the path specified by $p but with the
name it already has - giving a success state - but then the filesize
command failing to return a file size because it cannot find a file in
the name you gave it. Try doing an echo on $p and $i_name.
Also, please note that this all may depend on whether you are using
PHP 3 or PHP 4, and whether you have track_vars turned on. I've spent
ages getting an old PHP 3 upload script working in PHP 4 simply
because I didn't realise that the _name suffixed variable no longer
got set up! If you are using PHP 4, then you should be using variables
like:
$HTTP_POST_FILES['userfile']['name']
rather than:
$userfile_name
Hope this helps.
Adam
|
 |
|