How to parse JSON in JavaScript to take value

后端 未结 6 1241
陌清茗
陌清茗 2020-12-06 23:58

I am really stuck in parsing a JSON string and take it\'s values. I got the JSON string as

{\"user\":{\"id\":\"1\",\"firstname\":\"Freelogin\",\"created\":\         


        
6条回答
  •  执念已碎
    2020-12-07 00:37

    You should use jQuery.parseJSON. It will use native JSON if available, and only use eval if necessary, after a sanity check.

提交回复
热议问题