Re: [PHP-DEV] fputcsv() and $escape character

2018-09-13 Thread Rowan Collins
On 13/09/2018 16:55, Theodore Brown wrote: If the patch was also applied to PHP 7.2 and 7.1, we wouldn't need to add fallback code in the League/Csv library for these versions. I understand if this isn't possible, but I'm trying to figure out how best to approach fixing the issue in League/Csv.

Re: [PHP-DEV] fputcsv() and $escape character

2018-09-13 Thread Christoph M. Becker
On 13.09.2018 at 17:55, Theodore Brown wrote: > On Thursday, September 13, 2018 at 7:30 AM Christoph M. Becker > wrote: > >> I've submitted . > > Thanks so much for your work on this! Do you know if the patch can be > included in PHP 7.3? > > If the p

Re: [PHP-DEV] fputcsv() and $escape character

2018-09-13 Thread Theodore Brown
On Thursday, September 13, 2018 at 7:30 AM Christoph M. Becker wrote: >> Ironically, the League/Csv library uses `fputcsv()` behind the scenes, >> and thus suffers from the same escape character problem >> (see https://github.com/thephpleague/csv/issues/307). >> >> Is there any chance `fputcsv()

Re: [PHP-DEV] fputcsv() and $escape character

2018-09-13 Thread Christoph M. Becker
On 09.09.2018 at 16:55, Theodore Brown wrote: > On Friday, Sep. 22, 2017 at 5:09 PM Christoph M. Becker > wrote: > There are several bug reports regarding "broken" `fputcsv()` behavior in our tracker, namely, because the $escape parameter causes unexpected results. For instance:

Re: [PHP-DEV] fputcsv() and $escape character

2018-09-09 Thread Theodore Brown
On Friday, Sep. 22, 2017 at 5:09 PM Christoph M. Becker wrote: >>> There are several bug reports regarding "broken" `fputcsv()` behavior >>> in our tracker, namely, because the $escape parameter causes unexpected >>> results. For instance: >> >> I looked at fixing some of the CSV related bugs ab

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-22 Thread Christoph M. Becker
On 21.09.2017 at 23:08, Dan Ackroyd wrote: > On 21 September 2017 at 12:43, Christoph M. Becker wrote: > >> There are several bug reports regarding "broken" fputcsv() behavior in >> our tracker, namely, because the $escape parameter causes unexpected >> results. For instance: > > I looked at fi

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-22 Thread Andreas Hennings
On Fri, Sep 22, 2017 at 1:20 PM, Christoph M. Becker wrote: >> please make sure the behaviour of common applications, most notably >> Excel, is considered and tested. In my experience it has its own quirks, >> and it's likely that a large proportion of users require >> interoperability with it. It

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-22 Thread Christoph M. Becker
On 21.09.2017 at 20:01, Rowan Collins wrote: > On 21 September 2017 18:32:57 BST, Andreas Hennings > wrote: > >> So empty string would enable the standard behavior RFC 7111 with no >> escape char. >> If so, I support this. > > Just a note regarding standards: Actually, there is no accepted st

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Andreas Hennings
On Thu, Sep 21, 2017 at 1:43 PM, Christoph M. Becker wrote: > I don't think the current behavior is a bug, but rather the escape > character is an extension to the CSV "standard" (RFC 7111). Are you sure you mean RFC 7111 ? I was just parrotting the number in my previous email, but now I looked i

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Andreas Hennings
On Thu, Sep 21, 2017 at 11:08 PM, Dan Ackroyd wrote: > On 21 September 2017 at 12:43, Christoph M. Becker wrote: >> Hi everybody! >> >> There are several bug reports regarding "broken" fputcsv() behavior in >> our tracker, namely, because the $escape parameter causes unexpected >> results. For i

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Dan Ackroyd
On 21 September 2017 at 12:43, Christoph M. Becker wrote: > Hi everybody! > > There are several bug reports regarding "broken" fputcsv() behavior in > our tracker, namely, because the $escape parameter causes unexpected > results. For instance: I looked at fixing some of the CSV related bugs ab

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Rowan Collins
On 21 September 2017 18:32:57 BST, Andreas Hennings wrote: >So empty string would enable the standard behavior RFC 7111 with no >escape char. >If so, I support this. Just a note regarding standards: please make sure the behaviour of common applications, most notably Excel, is considered and test

Re: [PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Andreas Hennings
So empty string would enable the standard behavior RFC 7111 with no escape char. If so, I support this. I don't know if '' or true / false / null should be this "special value". It has to be something that was not legal before, and that people should use intentionally and not by accident. I guess

[PHP-DEV] fputcsv() and $escape character

2017-09-21 Thread Christoph M. Becker
Hi everybody! There are several bug reports regarding "broken" fputcsv() behavior in our tracker, namely, because the $escape parameter causes unexpected results. For instance: outputs "a\"",bbb instead of the expected "a\""",bbb I don't think the current behavior is a bug, but