Chmod
Posted: Mon May 29, 2006 3:27 pm
I wanted to use chmod() to change the permission on a config.inc.php after a setup.php script had finished. To make it so it couldn't be written to (0755).
But I can't get it to work!
I'm using PHP4 so ftp_chmod is not available.
I've tried fiddling with the directory permissions and the permission of the file to 777 (albeit just while playing!) and it just doesn't work. Safe mode is off.
I've hashed out my username for security!
Any clues on what to try next?
But I can't get it to work!
I'm using PHP4 so ftp_chmod is not available.
I've tried fiddling with the directory permissions and the permission of the file to 777 (albeit just while playing!) and it just doesn't work. Safe mode is off.
Code: Select all
Warning: chmod(): Operation not permitted in /home/#####/public_html/guestbook/chmodtest.php on line 3Code: Select all
<?php
chmod("config.inc.php",0755);
?>