Hi
I am trying to write a php script for uploading a word doc resume file via a form
But I keep getting a invalid file error
here is my html form
<html>
<body>
<form action=“test.php” enctype=“multipart/form-data” method=“post”> Please choose a file: <input name=“uploaded” type=“file” /><br /> <input type=“submit” value=“Upload” /> </form>
</body>
</html>
Here is the php script
<?php
$target = “upload/”;
$target = $target . basename( $_FILES[‘uploaded’][‘name’]) ;
$ok=1;
if(move_uploaded_file($_FILES[‘uploaded’][‘tmp_name’], $target))
{
echo "The file “. basename( $_FILES[‘uploadedfile’][‘name’]). " has been uploaded”;
}
else {
echo “Sorry, there was a problem uploading your file.”;
}
?>
I have not changed any names in the php script above .Only thing I did was create a upload folder in my directory on my server .But I keep getting the error Sorry there was a problem uploading your file
Please reply ASAP