Image file uploading is not taking place. This is the html code : <html> <body> <FORM ENCTYPE="multipart/form-data" ACTION="uploadtest.php" METHOD=POST> Send this file: <INPUT NAME="userfile" TYPE="file"> <INPUT TYPE="submit" VALUE="Send File"> </FORM> </body> </html>
This is the php file - uploadtest.php <? if (is_uploaded_file($userfile)) { echo "inside if "; copy($userfile, "/img"); } else { echo "Possible file upload attack: filename '$userfile'."; } //move_uploaded_file($userfile, "/img"); echo "file upload over"; ?> When I run the html and submit it - I get messages "Inside if " and at the end "file upload over" But when I check the directory /img - there is nothing inside. i.e. no file is getting uploaded. What is missing ? thanks in advance, manisha