Wednesday, October 8, 2008

Javascript: Conflict between jQuery and json.js

There’s a conflict between jQuery and Douglas Crockford’s json.js. The reason is that json.js tries to add a toJSONString() function to every object. The solution is to get a json2.js from http://www.json.org/json2.js. json2.js differs from the first version by using “a single base object (JSON) instead of extending all native object prototypes”.

No comments: