I have a problem with a piece of JSON and PHP\'s json_decode(). We receive JSON from a customer\'s publishing solution, and although it validates, json_decod
json_decode()
json_decod
just to add a possible option...
the library jsonlint can be used to validate your json string. It will take arguments to either ignore/detect duplicate keys.
whilst this wont fix your problem, at least youd be able to detect any errors so avoiding data corruption.