Now, I've tried to upload a file of 100 KB to my server.
It only gives the error message "There was an error uploading the file, please try again".Page: http://yoshi2889creations.vacau.com/upload.html
and http://yoshi2889creations.vacau.com/uploader.phpHost: 000webhost (http://www.000webhost.com/)upload.html:
<html><head><title>Yoshi2889's Creations: Submit Project</title></head><body>
<form enctype="multipart/form-data" action="uploader.php" method="POST">
<input type="hidden" name="MAX_FILE_SIZE" value="500" />
Choose a file to upload: <input name="uploadedfile" type="file" />
<input type="submit" value="Upload File" />
</form>uploader.php:<?php
$target_path = "NEW/";
$target_path = $target_path . basename( $_FILES['uploadedfile']['name']);
if(move_uploaded_file($_FILES['uploadedfile']['tmp_name'], $target_path)) {
echo "The file ". basename( $_FILES['uploadedfile']['name']).
" has been uploaded";
} else{
echo "There was an error uploading the file, please try again.";
}
?>Anyone know how to fix this or know a better script?