hi all
Here is the upload script i am working on
$file = $_FILES['userfile']['name'];
$file = $_FILES['userfile']['name'];
echo $file;
$file_type = $_FILES['userfile']['type'];
echo $file_type;
if($file_type=="image/pjpeg"||$file_type=="image/gif")
{
if($file_type=="image/pjpeg")
{
$destination = "images/".$file;
if(move_uploaded_file($_FILES['userfile']['tmp_name'], $destination)) //line no 105
{
echo 'Upload file success!';
}
}
if($file_type=="image/gif")
{
$destination = "images/".$file;
if(move_uploaded_file($_FILES['userfile']['tmp_name'], $destination))
{
echo 'Upload file success!';
}
}
if(!move_uploaded_file($file,$destination))
{
$Error=4;
}
}
else
{
echo "some error message";
}
This script returns the warning
Warning: move_uploaded_file(images/israel.gif) [function.move-uploaded-file]: failed to create stream: Permission denied in /usr/www/htdocs/somedomain/test/imageupload.php on line 105
Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move '/tmp/phpztd8tq' to 'images/israel.gif' in /usr/www/htdocs/somedomain/test/imageupload.php on line 105
I do have shell acces to the place
Please help me
Any kind of help would be appreciated
Thanks in advance
Greg