I am having a problem with my file uploads.... I have the html post the file info:
<form enctype="multipart/form-data" action="upload.php" method="POST">
<input type="hidden" name="MAX_FILE_SIZE" value="30000" />
Send this file: <input name="uploadfile" type="file" />
<input type="submit" value="Send File" />
</form>
then the upload.php
<?php
$path = "/uploads/";
$targetpath = $path . basename($_FILES['uploadfile']['name']);
echo '<pre>';
if(move_uploaded_file($FILES['uploadfile']['tmp_name'], $targetpath)) {
**echo "The file ". basename( $FILES['uploadedfile']['name']). " has been uploaded";
} else{
**echo "There was an error uploading the file, please try again!";
}
print "</pre>";
?>
I get:
Parse error: parse error in /Library/WebServer/Documents/ical/upload.php on line 9
What am I doing wrong?
THANKS