View Full Version : wrong parameter issue

08-12-2007, 09:36 AM
I have the following code:

"upload/" . $prefix, $_FILES["file"]["name"]);
echo "Stored in: " . "upload/" . $prefix, $_FILES["file"]["name"];

$prefix is defined as $session->username;

$prefix = $session->username;

and for some reason I keep getting the wrong parameter error no matter what i do. the only way to get rid of the error is to get rid of $prefix, but I need it there to add a prefix to the uploaded file.

Warning: Wrong parameter count for move_uploaded_file() in /home/.interrogator/sfox8/graphytecomics/upload_file.php on line 28

I'm really out of ideas now.

08-12-2007, 10:19 AM
you have a , after $prefix when it should be a .

08-12-2007, 06:46 PM
you have a , after $prefix when it should be a .

Yep, both of them.

08-12-2007, 07:25 PM
thank you so much guys. I feel like an idiot for not noticing a problem that small.