Hi, im trying to get this file upload script to work for my website, but it keeps sending me back this error:
Warning: move_uploaded_file(gallery/2004-2005/pics/anchorman01.jpg): failed to open stream: Permission denied in /hsphere/local/home/bulldog/centennialbulldogs.org/upload.php on line 24
Warning: move_uploaded_file(): Unable to move ‘/tmp/phpVbpouX’ to ‘gallery/2004-2005/pics/anchorman01.jpg’ in /hsphere/local/home/bulldog/centennialbulldogs.org/upload.php on line 24
i just can’t figure it out. I CHMOD the upload folder, the script, and it still wont work. Please help.
Here is the script:
[php]
"; //Debug $name = $_FILES['upload']['name']; $type = $_FILES['upload']['type']; $size = $_FILES['upload']['size']; $tmp = $_FILES['upload']['name']; echo "Name: $name
Type: $type
Size: $size
Tmp: $tmp"; } } else{ echo 'Could Not Upload Files'; } ?>
<form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" enctype="multipart/form-data">
<fieldset>
<legend>Upload Files</legend>
<input type="file" name="upload" />
[/php]
MOD EDIT: Added PHP bb code tags
Please view http://phphelp.com/forums/viewtopic.php?t=2564 for tiips on posting.