ID: 29163 Comment by: php at tntweb dot f9 dot co dot uk Reported By: ramon_herrera at eloyalty dot com Status: Assigned Bug Type: Filesystem function related Operating System: win2k & GNU/Linux (FC2) PHP Version: 5.0.1 Assigned To: moriyoshi New Comment:
White space between fields should be ignored, so the field ..., ,... should be returned as an empty string and not a single space. The latest PHP 4 version breaks this and returns a single space. To include leading or trailing spaces then they must be quoted. For further info read http://www.creativyst.com/Doc/Articles/CSV/CSV01.htm Previous Comments: ------------------------------------------------------------------------ [2004-08-13 08:12:12] ramon_herrera at eloyalty dot com IMO, correctness trumps backwards compatibility in this case, especially since pre-4.3.4 was so long ago. Compatibility with something that was broken is not a persuasive argument. If a single space char is what a CSV field is comprised of, then, IMO, that is exactly how it should be represented in this function's result. Must there be quotes? Backslash escapes? What else is needed? Moriyoshi, what do your colleagues believe? ------------------------------------------------------------------------ [2004-08-13 07:16:39] ramon_herrera at eloyalty dot com This bug shows up in version 5.0.1 under Fedora Core 2. ------------------------------------------------------------------------ [2004-08-12 08:25:01] ramon_herrera at eloyalty dot com The bug still shows up in CVS php5-200408120430 under Fedora Core 2. ------------------------------------------------------------------------ [2004-08-04 08:33:33] ramon_herrera at eloyalty dot com Is this bug destined to be fixed in a later release? ------------------------------------------------------------------------ [2004-07-21 05:54:07] ramon_herrera at eloyalty dot com Is this a matter of compatibility versus correctness? What is the consensus among the developers/maintainers regarding this matter? Thanks again. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/29163 -- Edit this bug report at http://bugs.php.net/?id=29163&edit=1
