Posted By

omerta83 on 07/08/10


Tagged

javascript jquery


Versions (?)

How to convert JSON string into a JavaScript Object


 / Published in: JavaScript
 

  1. var obj = jQuery.parseJSON('
  2. {"name":"Larry King",
  3. "age": "5000"
  4. }');
  5. alert( obj.name === "Larry King" ); //true
  6. alert (obj.age === "50"); //false
  7. alert (obj.age === "5000"); //true
  8.  

Report this snippet  

You need to login to post a comment.