Graceful Degradation with JSON.Parse
Posted
by Steve
on Stack Overflow
See other posts from Stack Overflow
or by Steve
Published on 2010-06-07T20:18:11Z
Indexed on
2010/06/07
20:22 UTC
Read the original article
Hit count: 254
If a browser doesn't support JSON.parse, would it make sense to include json.js and call parseJSON in lieu?
So the code would looks something like:
var z;
if (JSON.parse)
z = JSON.parse(yada);
else
z = JSON.parseJSON(yada);
© Stack Overflow or respective owner