Forum Moderators: coopster
Warning: unlink(/home/star/public_html/PropertyDB/Images/29/type-b1.jpg): Permission denied in /home/star/public_html/PropertyDB/ImageDelete.php on line 31
Warning: Cannot modify header information - headers already sent by (output started at /home/star/public_html/PropertyDB/ImageDelete.php:31) in /home/star/public_html/PropertyDB/ImageDelete.php on line 36
I've spoken to the host about folder permissions on the server but they keep blaming the scripts saying:
"For example, on Line 34 of ImagePosting.php you have this : chmod( $uploadfile, 0744 );
which changes permissions ... it also occurs elsewhere... but does not seem to reset/restore the permissions.. "
Since the host is blaming the scripts and I'm no PHP expert does anybody have any idea how I can resolve this?
dc
For more info see:
[uk.php.net...]
if(server_software == "LNX") {Where server_sofware is a defined constant in 'cofig.inc.php'.
$handle = fopen($target, r);
chmod($target, 0777);
}
if(server_software == "WIN")
$handle = fopen($target, w);
fwrite($handle, $write_to_file);
if(server_software == "LNX")
chmod($target, 0644);
fclose($handle);
However the directory which has my files is '0777' premanently set using FTP program, I don't like this; but I can't do it runtime using PHP. Hope you can now do. Otherwise check if PHP is running in SAFE_MODE; check o/p of phpinfo(); ;)