X-Git-Url: http://git.asbjorn.it/?a=blobdiff_plain;f=src%2Fajax%2Fajax.js;h=7bd392aa2374a8837713d9b711da8334142f0238;hb=805d21c2360a10fa5e7ac85cc593b4403afb6c9f;hp=e9580aa8a2d8a75a27299aa422cf40c679233935;hpb=874e4f65eecdf74bb76c361d778aac4ed6158ed6;p=jquery.git diff --git a/src/ajax/ajax.js b/src/ajax/ajax.js index e9580aa..7bd392a 100644 --- a/src/ajax/ajax.js +++ b/src/ajax/ajax.js @@ -58,7 +58,7 @@ jQuery.fn.load = function( url, params, callback, ifModified ) { }; // If IE is used, create a wrapper for the XMLHttpRequest object -if ( jQuery.browser.msie ) +if ( jQuery.browser.msie && typeof XMLHttpRequest == "undefined" ) XMLHttpRequest = function(){ return new ActiveXObject( navigator.userAgent.indexOf("MSIE 5") >= 0 ? @@ -274,6 +274,9 @@ jQuery.extend({ // If the type is "script", eval it if ( type == "script" ) eval.call( window, data ); + // Get the JavaScript object, if JSON is used. + if ( type == "json" ) eval( "data = " + data ); + return data; },