PDA

View Full Version : load function



joecool2005
11-20-2006, 07:27 PM
Hi,

When I call like this

set licxmldoc = server.CreateObject("Microsoft.XMLDOM")
licxmldoc.async = false
licxmldoc.load("http://www.w3schools.com/xml/note.xml")

it does not work. But when I test the link on the browser, it works!


Can somebody tell me why I cannot call?

Thx
Joe

SindicatoESP
11-22-2006, 05:55 AM
The syntax you posted was in ASP.

This is the javascript equivalent of ur code.

var licxmldo = new ActiveXObject("Microsoft.XMLHTTP"); //IE
//var licxmldo = new XMLHttpRequest(); // mozilla
licxmldoc.async = false;
licxmldoc.open("GET", "http://www.w3schools.com/xml/note.xml", true);
........
........
licxmldoc.send(null);


You can search for AJAX code snippet for more reference.