...

View Full Version : wrong parameter issue



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



move_uploaded_file($_FILES["file"]["tmp_name"],
"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.

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

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

Yep, both of them.

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



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum