Loading xml with Jquery - why doesn't this work
Posted
by es11
on Stack Overflow
See other posts from Stack Overflow
or by es11
Published on 2010-06-01T19:34:12Z
Indexed on
2010/06/01
22:13 UTC
Read the original article
Hit count: 238
I have regular javascript code and am trying to utilize JQuery just to load and parse an xml file. I have the following:
function loadXml() {
$(function() {
$.ajax({
type: "GET",
url: "my_file.xml",
dataType: "xml",
success: parseXml
});
});
}
function parseXml() {
alert("Parsing...");
}
When calling loadXml
I cannot get the callback success function to execute. I am running this all locally and my_file.xml
resides in the same directory as this javascript. Any ideas?
© Stack Overflow or respective owner