ID:               33179
 User updated by:  fsb at thefsb dot org
 Reported By:      fsb at thefsb dot org
 Status:           Bogus
 Bug Type:         Filesystem function related
 Operating System: os x 10.3 and freebsd 5.3
 PHP Version:      4.3.10
 New Comment:

snipper,

both are turned off.

since you changed the state back to bogus i assume that 
your note was not a request for more information about 
the bug. i suppose i should take the hint and just stop 
bothering people.


Previous Comments:
------------------------------------------------------------------------

[2005-06-06 10:25:31] [EMAIL PROTECTED]

Check you magic_quotes_* settings in php.ini..


------------------------------------------------------------------------

[2005-06-04 01:49:45] fsb at thefsb dot org

iliaa, please see my update from 6/1. i omitted to 
change the status to open when i submitted it.

------------------------------------------------------------------------

[2005-06-01 02:25:24] fsb at thefsb dot org

if backslash were an escape character to PHP then it 
would not appear in the parsed values from the following 
csv file:

abc,123,abc,123,abc,123
abc,\ 123,abc,123,abc,123
abc,123\ ,abc,123,abc,123
abc,123,abc\,123,abc,123
abc,123,\"abc",123,abc,123
abc,123,"a\""bc",123,abc,123
abc,123,"a"\"bc",123,abc,123
abc,123,"a""bc"\ ,123,abc,123

in every case above, the backslash preceeds a special 
caracter in the csv file format. if backshalsh were 
generally an escape character then in these positions it 
should be removed by the csv parser leaving the 
following character as literal.

------------------------------------------------------------------------

[2005-05-31 01:18:39] [EMAIL PROTECTED]

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

As far as PHP is concerned backslash is an escape characte, which makes
the demonstrated behaviour expected.

------------------------------------------------------------------------

[2005-05-30 02:22:52] fsb at thefsb dot org

Description:
------------
why can i have a \ at the end of a field but not
if i wrap it in " field delimiters? e.g.

  abc,123\,abc       works fine but

  "abc","123\",abc   produces only two columns

this question has been asked before (#29278, #30476,
etc.) and [EMAIL PROTECTED] rejects the bug as bogus. i 
don't agree. 

if this is not a bug then this unusual use of \ to 
escape only closing field delimiting double quotes 
but not escape any other instances of double qotes or 
(it would appear) any other character SHOULD be 
documented. it is not.

moreover this undocumented feature is not consistent 
with the specification of the CSV file format found 
here: http://www.creativyst.com/Doc/Articles/CSV/
CSV01.htm

this csv spec suggests that backslash has no special 
meaning in the CSV format at all. indeed, in all my 
tests, fgetcsv appears to accord it no special meaning 
_except_ in this one particular case.

such a surprising behaviour that deviates from common 
CSV file format conventions SHOULD be documented (or 
corrected).



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=33179&edit=1

Reply via email to