cancel
Showing results for 
Search instead for 
Did you mean: 

xmlhttprequest/IServerXMLHTTPRequest2 created in framework.pack.js?

Bauke_Roo
Star Contributor
Star Contributor

Hi,

Im trying to create a custom ajax request in Internet Explorer. About halfway my code i'm trying the following line:

xhr = new XMLHttpRequest();

Instead of getting a regular xmlhttprequest object I'm getting a "[object IServerXMLHTTPRequest2]" During the code in the line above a jump is made to the framework.pack.js and a ISserverXMLHTTPRequest2 is made, to the following lines in framework.pack.js:

XMLHttpRequest=function(){if(!_SARISSA_XMLHTTP_PROGID){_SARISSA_XMLHTTP_PROGID=Sarissa.pickRecentProgID(["Msxml2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"])
}return new ActiveXObject(_SARISSA_XMLHTTP_PROGID)
};

Is there a way to avoid this, I need a regular XMLHttpRequest object.

Edit: I should add: I'm using nuxeo 5.8 and IE11.

Thanks in advance, Bauke Roo

1 REPLY 1

Bauke_Roo
Star Contributor
Star Contributor

It seems that it happened before with jQuery: http://fisheye.nuxeo.com/browse/nuxeo-dm/nuxeo-platform-webapp/src/main/resources/web/nuxeo.war/scri...

the solution seems to be the following:

if (Sarissa.originalXMLHttpRequest) {
        xhr = new Sarissa.originalXMLHttpRequest();
    }else if (window.XMLHttpRequest) {
        xhr = new XMLHttpRequest();
    } else if (window.ActiveXObject) {
    xhr = new ActiveXObject("Microsoft.XMLHTTP");
}

Bauke Roo

Getting started

Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.