// Licensed Materials - Property of IBM // // IBM Cognos Products: ps // // (C) Copyright IBM Corp. 2005, 2011 // // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. // Copyright (C) 2008 Cognos Incorporated. All rights reserved. // Cognos and the Cognos logo are trademarks of Cognos Incorporated. var xmlHttpVersions = [ "Msxml2.XMLHTTP.6.0", "Msxml2.XMLHTTP.3.0", "Msxml2.XMLHTTP", "Microsoft.XMLHTTP" ]; function findXMLHttpActiveXVersion() { if (window.ActiveXObject) { var i, l = this.xmlHttpVersions.length; for (i = 0; i < l; i++) { try { // Try and create the ActiveXObject for Internet Explorer, if it doesn't work, try again. var xmlhttp = new ActiveXObject(this.xmlHttpVersions[i]); if (xmlhttp) return this.xmlHttpVersions[i]; } catch (e) { // this ActiveX is not there, continue with next one in list } } } return null; } var xmlHttpDefault = findXMLHttpActiveXVersion(); function getXMLHttpRequest() { if (xmlHttpDefault != null) return new ActiveXObject(xmlHttpDefault); // Well if there is no ActiveXObject available it must be firefox, opera, or something else if (typeof XMLHttpRequest != 'undefined') { try { return new XMLHttpRequest(); } catch (e) { alert(e); } } throw "No XMLHttpRequest object is available"; }