See anything wrong with this JSON2 push/stringify?
Posted
by nobosh
on Stack Overflow
See other posts from Stack Overflow
or by nobosh
Published on 2010-06-06T02:22:13Z
Indexed on
2010/06/06
2:32 UTC
Read the original article
Hit count: 225
dynamictextareas.push({guideid:targeteditorID, guideitemtext : textareacontents });
alert( JSON.stringify(dynamictextareas) );
See anything wrong with this JSON2 javascript code?
For some reason this come is making a mess of things. I want to push:
<p>DDDDDD</p>
But instead it's pushing:
[{"guideid":"1","guideitemtext":"<p>\u000a\u0009u000au0009DDDDDD</p>\u000a"}]
Any ideas? Is there a better way I can build this JSON object?
© Stack Overflow or respective owner