I have a upload file option that works fine. And then I have a page that shows all the files in that folder with a link with the full path to the file. Everything works fine on my machine and have tested it on a couple other servers, but the one that I need to run this on I'm getting this problem:
When I upload the file using the browse option It works and I can see it on the page with the downloadable link. But the download link brings up a 404 error that it does not exist even though the path is correct and the file is there. If I upload it using ftp software it works fine. I have the direcrory set to CHMOD 777. Any Ideas?
here's the php for the upload.
<?
$uploaddir = '/var/www/html/mypath/';
$uploadfile = $uploaddir . basename($_FILES['UPLOAD']['name']);
if (move_uploaded_file($_FILES['UPLOAD']['tmp_name'], $uploadfile)) {
echo "File Uploaded";
}else{
print_r($_FILES);
}
?>
Thanks