Re: fputcsv()

From: Date: Mon, 12 Apr 2004 00:52:57 +0000
Subject: Re: fputcsv()
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-9047@lists.php.net to get a copy of this message
On 2004/04/12, at 1:33, David Sklar wrote:
Attached is a patch that implements fputcsv() as a complement to fgetcsv(). There are two things that still need improvement: - It adds "\n" as a newline onto the end of each line. I think it would be better to add a platform-specific line ending. - It is not mbstring-aware.
As for writing stuff, we don't have to care about in which encoding strings are encoded as long as it is 8-bit compatible. UTF-16 / UTF-32 / UCS-2 / UCS-4 are not 8-bit compatible and I've never seen a case where one of these is utilised for CSV files, so I think your code is actually "multibyte safe" :) Moriyoshi
Any suggestions for fixing these things (or other issues) would be appreciated. Thanks, David


« previous php.internals (#9047) next »