Inspired? No home

XMLHTTPrequest and DOMDocument - cross-browser

This is an AJAX example on how to use my cross-browser XMLHTTPRequest and DOMDocument script. It can used for three things:

1. Execute HTTP POST/GET request to another server and get the response using XMLHTTPRequest.

2. Load XML documents using DOMDocument.

3. Check if client supports the above methods, and which version of the Microsoft XML Parser (MSXML) is installed.

Click the ‘execute script’ button below to display debug data for your browser and contents of one html and one xml file.

<iframe src="http://inspired.no/sleepyhead/objxml/objXML.html" style="border: 2px groove ; background: silver none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial; height: 400px; width: 100%;"></iframe>

<iframe src="http://inspired.no/sleepyhead/objxml/objXMLSniffer.txt" style="border: 2px groove ; background: silver none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial; height: 400px; width: 100%;"></iframe>

Download the JavaScript source file here.

Technorati: , , ,

Written on 18 May 2005.
blog comments powered by Disqus