Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Escaping quotes in JSON string

by nikosv (Deacon)
on Oct 12, 2015 at 10:40 UTC ( [id://1144507]=note: print w/replies, xml ) Need Help??


in reply to Escaping quotes in JSON string

your sample doesn't validate, even before the quotes have been examined

Furthermore, shouldn't the JSON serializer working on the original source/structure be producing valid JSON anyway?

Error:Expecting string or }, not [.Code 4, Structure 2
Error:Strings should be wrapped in double quotes.Code 17, Structure 4
Error:Strings should be wrapped in double quotes.Code 17, Structure 6
Error:Strings should be wrapped in double quotes.Code 17, Structure 8
Error:Strings should be wrapped in double quotes.Code 17, Structure 10
Error:Strings should be wrapped in double quotes.Code 17, Structure 12
Error:Strings should be wrapped in double quotes.Code 17, Structure 14
Error:Invalid characters found.Code 18, Structure 14
Error:Strings should be wrapped in double quotes.Code 17, Structure 18
Error:Strings should be wrapped in double quotes.Code 17, Structure 20
Error:Strings should be wrapped in double quotes.Code 17, Structure 22
Error:Strings should be wrapped in double quotes.Code 17, Structure 24
Error:Strings should be wrapped in double quotes.Code 17, Structure 26
Error:Strings should be wrapped in double quotes.Code 17, Structure 28
Error:Expecting comma, colon or }, not string.Code 11, Structure 29
Error:Strings should be wrapped in double quotes.Code 17, Structure 29
Error:Expecting comma, colon or }, not string.Code 11, Structure 30
Error:Strings should be wrapped in double quotes.Code 17, Structure 30
Error:Invalid characters found.Code 18, Structure 30
Error:Strings should be wrapped in double quotes.Code 17, Structure 34
Error:Strings should be wrapped in double quotes.Code 17, Structure 36
Error:Strings should be wrapped in double quotes.Code 17, Structure 38
Error:Strings should be wrapped in double quotes.Code 17, Structure 40
Error:Expecting comma, colon or }, not string.Code 11, Structure 41
Error:Strings should be wrapped in double quotes.Code 17, Structure 41
Error:Strings should be wrapped in double quotes.Code 17, Structure 43
Error:Strings should be wrapped in double quotes.Code 17, Structure 45
Error:Expecting comma, colon or }, not ].Code 11, Structure 46
Error:Expecting comma or ], not }.Code 6, Structure 47
Error:Expecting closing } at endCode 22, Structure 47

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1144507]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (4)
As of 2024-04-16 10:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found