Opened 13 years ago

Closed 13 years ago

#2194 closed enhancement (worksforme)

Internet Explorer 7.0 fails with new ActiveXObject("Microsoft.XMLHTTP")

Reported by: guest Owned by: dylan
Priority: blocker Milestone: 0.9
Component: General Version: 0.4.1
Keywords: Cc:
Blocked By: Blocking:

Description

Internet Explorer 7.0 now uses new XMLHttpRequest(), not new ActiveXObject("MicrosoftXMLHTTP") in "native" mode to get the XMLHttpRequest object.

This requires either that the client disable navtive XMLHTTP support under tools/Internet Options/Advanced?, or dojo.js be changed to reflect this new support, by adding the following, in bold.

dojo.hostenv.getXmlhttpObject=function(){
var _b9=null;
...

if(!_b9){
for(var i=0;i<3;++i){
var _bc=dojo.hostenv._XMLHTTP_PROGIDS[i];
try{
_b9=new ActiveXObject(_bc);
'''if(!_b9){
_b9=new XMLHttpRequest();
}'''

...

Glenn Silverman Exmbly Systems, Inc. glenn@…

Change History (2)

comment:1 Changed 13 years ago by dylan

Milestone: 0.5
Owner: changed from anonymous to dylan
severity: criticalblocker

comment:2 Changed 13 years ago by dylan

Resolution: worksforme
Status: newclosed

the code in the current Dojo trunk looks like this:

	dojo.hostenv.getXmlhttpObject = function(){
		// summary: does the work of portably generating a new XMLHTTPRequest object.
		var http = null;
		var last_e = null;
		try{ http = new XMLHttpRequest(); }catch(e){}
		if(!http){
			for(var i=0; i<3; ++i){
				var progid = dojo.hostenv._XMLHTTP_PROGIDS[i];
				try{
					http = new ActiveXObject(progid);
				}catch(e){
					last_e = e;
				}

				if(http){
					dojo.hostenv._XMLHTTP_PROGIDS = [progid];  // so faster next time
					break;
				}
			}

which I think is correct. If it is not, please reopen.

Note: See TracTickets for help on using tickets.