[xmljs-users] XmlHttpRequest Object
Brought to you by:
djoham,
witchhunter
From: Heath B. <hea...@gm...> - 2005-01-06 14:26:50
|
I'm trying to use the XmlHttpRequest Object to make requests back to my web server to retrieve some Xml data. The request object itself works fine and the request comes back just fine. However, every time I make the request, my browser prompts my about using an ActiveX control that is safe for scripting. The example websites I've viewed that use the XmlHttpRequest Object call it the same way I do, and I don't get this warning when I view those pages. Here is a link to an example page: http://developer.apple.com/internet/webcontent/XMLHttpRequestExample/example.html Here is my function that actually calls the XmlHttpRequest Object: function loadXMLDoc(url) { // branch for native XMLHttpRequest object if (window.XMLHttpRequest) { req = new XMLHttpRequest(); req.onreadystatechange = processReqChange; req.open("GET", url, true); req.send(null); // branch for IE/Windows ActiveX version } else if (window.ActiveXObject) { req = new ActiveXObject("Microsoft.XMLHTTP"); if (req) { req.onreadystatechange = processReqChange; req.open("GET", url, true); req.send(); } } } -- -Heath Borders-Wing hbo...@ma... |