Re: [PATCH] Bug #46367 - fputcsv does not add the correct newline character on Windows
| From: | Brian Moon | Date: | Tue, 07 Jul 2009 19:22:57 +0000 |
| Subject: | Re: [PATCH] Bug #46367 - fputcsv does not add the correct newline character on Windows | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-44789@lists.php.net to get a copy of this message | ||
On 7/7/09 1:27 PM, Jani Taskinen wrote:
John Mertic kirjoitti:The only program I know of in existence that has issues is Notepad on Windows. All the mac programs I use will deal with whatever. Having said that, it should be just as flexible for creating CSV files as fgetcsv is for reading them. Of course, a good ol' fputs does a fine job of making a CSV file too. -- Brian. -------- http://brian.moonspot.net/Hi All, Bringing this one back once more; let me know what everyone thinks about it. If it's safe to commit than if someone could ( or give me the karma to do so ) that would be great. If not, let me know what should be done about it instead.Is \r\n okay on Mac? Is \r okay on Windows? etc. Short: Shouldn't this be always \r\n? Or better yet, default to \r\n and add extra option for fputcsv with which you can set it to anything you like.. :) --Jani