How to change the Browser Object Model version Window object "DispHTMLWindow2" to "Window" in Javascript for IE5 Browser
Here, am checking the browser BOM object windows version in IE5 browser. It isshowing [object DispHTMLWindow2]
and condition true object create regarding with the version. I need the object to change in "Window" how to change the BOM version in Javascript.
Note : I am not able to change the browser version IE5.
Error : This client Javascript is lower version. We tried communication with the PHP server but it is not supporting the version of Javascript, but if I run the application in higher version like Edge and IE11 its working fine and the BOM object is Window, that’s why I’m trying to change the BOM version value.
function HPF_Click() { var currentLocation = document.getElementById("ddlurl").value; var objectType = document.getElementById("ddlobject").value; var activexModes = ["Microsoft.XMLHTTP"]; // For ActiveX var logUrl = currentLocation; if (window.ActiveXObject) { for (var i = 0; i < activexModes.length; i++) { try { Ajax = new ActiveXObject(activexModes[i]); if (Ajax) break; } catch (e) { } } } else if (window.XMLHttpRequest) { Ajax = new XMLHttpRequest(); } if (Ajax && currentLocation) { postData = "messagedata"; Ajax.open('POST', logUrl, true); Ajax.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded'); Ajax.send(postData); return true; } return false; }