Re: carriage return (writing files)
| From: | Jack Dempsey | Date: | Wed, 09 May 2001 08:08:55 +0000 |
| Subject: | Re: carriage return (writing files) | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-52049@lists.php.net to get a copy of this message | ||
Magnus Lawrie wrote:
>
> hello,
> I'm writing to files with php. How do I include a carriage return, i.e.
> write strings to different lines in a text file?
> Thanks,
>
> --
> 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
echo "foo\n"; #<-- the \n is a newline
echo "foo\r"; #<-- the \r is a carriage return
what you use will depend on what system you're working on...if *nix, \n
will do...
-jack