Make prototype.js first test for XMLHttprequest object

and then the IE active-x thingies. This forces IE 7 to use
the native XMLHttprequest object. (and debugging on gecko
browsers easier)
This commit is contained in:
Anders Betnér 2006-06-07 06:54:24 +00:00
parent 18f72b5135
commit 4004a0f7df

View File

@ -549,9 +549,9 @@ var $R = function(start, end, exclusive) {
var Ajax = {
getTransport: function() {
return Try.these(
function() {return new XMLHttpRequest()},
function() {return new ActiveXObject('Msxml2.XMLHTTP')},
function() {return new ActiveXObject('Microsoft.XMLHTTP')},
function() {return new XMLHttpRequest()}
function() {return new ActiveXObject('Microsoft.XMLHTTP')}
) || false;
},