Saving PHP output as a file

Posted on 16th Feb 2014 by admin

I wondered if anyone knows how to save the rendered output of a PHP script as a file?

I have a script that creates dynamic PDF documents, but want to save it as a file, rather than render it to the browser. could I do something like Code: $file=save_as_file(output('file.php'));
?
(I know the code above is wrong)

Other php-forum