joshbates15
Technical User
This is what I'm trying to do... On my website I would like to update content through an XML document. The XML document would look something like this:
<?xml version="1.0" encoding="ISO-8859-1"?>
<aaronsays>
<date>June 13th,2005</date>
<saying>I got wine on my sterling silver tie, trade me ties.</saying>
<saying>I think my mom steals things from my room when I'm gone!</saying>
...
</aaronsays>
Then my HTML document would look like this:
<html>
...
<div id="aaronsays">
<span id="date" style="display:block;;"> *** Date Info from XML goes Here *** </span>
<ul id="sayings">
*** List the saying XML Data as <li>'s in here ***
</ul>
</div>
...
</html>
I know I'm going to need to use some javascript (something I'm not too strong in) to import the XML data into the HTML document, probably through some XMLHttpRequest. I've looked at countless examples, apple, macrumorslive.com, but it just doesn't seem to totally click with me. I've tried the example in the faq, but didn't seem to work corectly. I would also like to make sure it will work in both Firefox and Internet Explorer. Any advice would be much appreciated!
<?xml version="1.0" encoding="ISO-8859-1"?>
<aaronsays>
<date>June 13th,2005</date>
<saying>I got wine on my sterling silver tie, trade me ties.</saying>
<saying>I think my mom steals things from my room when I'm gone!</saying>
...
</aaronsays>
Then my HTML document would look like this:
<html>
...
<div id="aaronsays">
<span id="date" style="display:block;;"> *** Date Info from XML goes Here *** </span>
<ul id="sayings">
*** List the saying XML Data as <li>'s in here ***
</ul>
</div>
...
</html>
I know I'm going to need to use some javascript (something I'm not too strong in) to import the XML data into the HTML document, probably through some XMLHttpRequest. I've looked at countless examples, apple, macrumorslive.com, but it just doesn't seem to totally click with me. I've tried the example in the faq, but didn't seem to work corectly. I would also like to make sure it will work in both Firefox and Internet Explorer. Any advice would be much appreciated!