Hi, any chance we could add a reviver option to the ajax settings for
JSON requests?
This could also be used by other plugins that parse JSON data too.

- Mark

Index: src/ajax.js
===================================================================
--- src/ajax.js (revision 6529)
+++ src/ajax.js (working copy)
@@ -182,7 +182,8 @@
                        json: "application/json, text/javascript",
                        text: "text/plain",
                        _default: "*/*"
-               }
+               },
+               jsonReviver: null
        },

        // Last-Modified header cache for next request
@@ -565,7 +566,7 @@
                        // Get the JavaScript object, if JSON is used.
                        if ( type === "json" ) {
                                if ( typeof JSON === "object" && JSON.parse ) {
-                                       data = JSON.parse( data );
+                                       data = JSON.parse( data, s.jsonReviver 
);
                                } else {
                                        data = (new Function("return " + 
data))();
                                }

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to jquery-dev@googlegroups.com
To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to