-   Programming (
-   -   URGENT:- PHP file handling help (

vinaypreet 11-15-2011 02:39 AM

URGENT:- PHP file handling help
i have to design a PHP interface on my fedora 13 using LAMP
i need to edit my SQUID.CONF file using PHP for my bandwidth manager project.

i'm unable to open or handle any file outside the HTML folder

$File = "/root/Desktop/YourFile.txt";
$Handle = fopen($File, 'w');
$Data = "Jane Doe\n";
fwrite($Handle, $Data);
$Data = "Bilbo Jones\n";
fwrite($Handle, $Data);
print "Data Written";

This simple code runs in HTML location but not on desktop....:(

acid_kewpie 11-15-2011 02:50 AM

Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place. This thread is being closed because it is a duplicate.

All times are GMT -5. The time now is 01:13 AM.