In all other non-IE browsers, the following code snippet works great:
<!DOCTYPE html>
<html>
<script type="text/javascript">
var xhr = new XMLHttpRequest();
var url = "https://otherdomain.com";
var method = "GET";
xhr.open(method, url, true);
xhr.onload = function() {
var responseText = xhr.responseText;
document.write(responseText);
};
xhr.send()
</script>
</html>
In two different IE11 browsers (running on different OS versions), I get two different errors:
- IE11 Win7: Script7002: XMLHttpRequest: Network Error 0x80070005, Access is denied.
- IE11 Win8: Script7002: XMLHttpRequest: Network Error 0x2eff Could not complete the operation due to error 00002eff
Google searches for the above error codes don't turn up anything useful. I've tried setting Content-Type, adding dummy functions for onprogress and onload, to no avail.