Hi everyone. I have been trying to navigate the DOM of an xml document that I am using ajax XMLHttpRequest to get. Here is the javascript source.
Code:
function requestPage(page)
{ 
   		var req = null; 

		if (window.XMLHttpRequest)
		{
 			req = new XMLHttpRequest();
			if (req.overrideMimeType) 
			{
				req.overrideMimeType('text/xml');
			}
		} 
		else if (window.ActiveXObject) 
		{
			try {
				req = new ActiveXObject("Msxml2.XMLHTTP");
			} catch (e)
			{
				try {
					req = new ActiveXObject("Microsoft.XMLHTTP");
				} catch (e) {}
			}
	        	}


		req.onreadystatechange = function()
		{ 
			
			if(req.readyState == 4)
			{
			
				if(req.status == 200)
				{
					
					
					// process a XML document here
					var doc = req.responseXML;

					

					var element = doc.getElementsByTagName('title').item(0);   // Read the first element
					document.getElementById('title').innerHTML = element.firstChild.nodeValue + 'finished';  

				}	
				else	
				{
					document.getElementById('title').innerHTML ="Error: returned status code " + req.status + " " + req.statusText;
				}	
			} 
		}; 
		req.open("GET", "bcsitecontent.xml", true); 
		req.send(null); 
} 



Here is a sample from the xml document:

<site>
	<home>
		<title>Welcome to Computer Science and Business Administration</title>
		<content>The &lt;span style="color:red;"&gt;Bakersfield College&lt;/span&gt; Business Administration department and
			Computer Science departments have been merged into one department.  This is the new deparmtent website.	
		</content>
	</home>
</site>
Anyway, I can successfully get information out of the title tag. What I need is to be able to get title and content information. So i was trying to get everything in the home tag and then be able to access everything beneath it. Does anyone have any thoughts on this.