[PHP-DEV] Re: json_encode() bug

2008-02-01 Thread Gaetano Giunta
Stanislav Malyshev wrote: ... The question is - should we have an error there? If so, which one - E_WARNING, E_NOTICE? I'm for E_WARNING. +1 Also please add at least a warning when errors are found in decoding process, so that it is somewhat feasible to distinguish a bad decode from json_de

[PHP-DEV] Re: json_encode() bug

2008-01-25 Thread Nathan Rixham
quick work around for now.. base64_decode(json_decode(json_encode(base64_encode("ab\xE0\" something" Stanislav Malyshev wrote: Hi! Right now, if json_encode sees wrong UTF-8 data, it just cuts the string in the middle, no error returned, no message produced. Example: var_dump(json_encode