X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fajax%2Fajax.js;h=b872481abf6046b90a2b86e3a3e30adf87cf39e2;hb=34c0bed54a5ad812b1f78a85529164e0085f50d7;hp=87fe73b943dc232769173bd7afc13526f7e3228b;hpb=5ebd5f604ac90dae6381f59cfa637621faabf932;p=jquery.git diff --git a/src/ajax/ajax.js b/src/ajax/ajax.js index 87fe73b..b872481 100644 --- a/src/ajax/ajax.js +++ b/src/ajax/ajax.js @@ -132,7 +132,7 @@ jQuery.fn.extend({ }); // If IE is used, create a wrapper for the XMLHttpRequest object -if ( jQuery.browser.msie && typeof XMLHttpRequest == "undefined" ) +if ( !window.XMLHttpRequest ) XMLHttpRequest = function(){ return new ActiveXObject("Microsoft.XMLHTTP"); }; @@ -799,7 +799,7 @@ jQuery.extend({ // Serialize the key/values for ( var j in a ) // If the value is an array then the key names need to be repeated - if ( a[j].constructor == Array ) + if ( a[j] && a[j].constructor == Array ) jQuery.each( a[j], function(){ s.push( encodeURIComponent(j) + "=" + encodeURIComponent( this ) ); });