RE: [PHP] Output to a file

From: Date: Mon, 14 Aug 2000 20:19:01 +0000
Subject: RE: [PHP] Output to a file
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-11680@lists.php.net to get a copy of this message
Here's a bit of code that may help you out: <?php $newfile = fopen("/path/to/new/file/mydata.txt", "a+"); // windows paths : // $newfile = fopen("c:\\path\\to\new\\file\\mydata.txt", "a+"); fwrite($newfile, "This is a new file."); fclose($newfile); echo "All done!"; ?> -----Original Message----- From: andy@penguin2.apolloi.com [mailto:andy@penguin2.apolloi.com]On Behalf Of Andrew Etemadi Sent: Monday, August 14, 2000 3:41 PM Cc: PHP General Subject: Re: [PHP] Output to a file Yes, open a file, write what you want into the file, and close the file. Jordan Pickup wrote: > Is there any way to specify that all output go to a file instead of stdout? > > jordan > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#11680) next »