Permission denied when executing 'copy' command in a PHP script

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In a PHP file upload script which looks like:

$htmlplace="aplace";
if ($_FILES['HtmlFile']['name'] != "")
{

	$filenamex = basename($_FILES['HtmlFile']['name']);
	copy($_FILES['HtmlFile']['tmp_name'],$htmlplace."/".$filenamex);
}

I am getting the error message:

<br />
<b>Warning</b>: copy(aplace/ahtml.html) [<a href='function.copy'>function.copy</a>]: failed to open stream: Permission denied in <b>/home/directory/anotherdirectory/makecopy2.php</b> on line <b>6</b><br />

This was working perfectly before so I am at a loss as to why it is now failing. Does anybody have any idea what could be happening and what the Permission denied refers to and means ? Thanks !




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux