I have an $output and I would like the output to be written to a text file, I dunno if it should go something like this
Code: Select all
$filename = "/usr/local/something.txt";
$handle = fopen($filename, "r");fwrite...
thank you
Moderator: General Moderators
Code: Select all
$filename = "/usr/local/something.txt";
$handle = fopen($filename, "r");Code: Select all
fwrite($handle, $content);Code: Select all
$filename = "/path/tp/file";
$fp = fopen($filename, "a"); //appends to the file r = read, w = write from start of file
fwrite($fp, "put this in the file");
fclose($fp);