I've seen a few posts around this forum and others with users attempting to use XML data islands in Mozilla. I decided that it might be fun, so I created a little function to replicate the XMLDocument property in Mozilla for data islands. It supports both external loading (through the src attribute), and inline XML. Hopefully it will be of use to someone.

oXMLLoader = {
	getXML: function(fnLoad) {
		function mkXMLDocumentByString(n) {
			return (new DOMParser()).parseFromString(n.innerHTML, 'text/xml');
		function mkXMLDocumentByRetrieval(n) {
			var xmldoc = new XMLHttpRequest();
			xmldoc.open('GET', n.getAttribute('src'), false);
			return xmldoc.responseXML;
		var xmlTags = document.getElementsByTagName('xml'), re = /\.xml$/i, holderObj;
		for(var i = 0, l = xmlTags.length; i < l; i++) {
			if(re.test(xmlTags.item(i).getAttribute('src'))) {
				holderObj = mkXMLDocumentByRetrieval(xmlTags.item(i));
				xmlTags.item(i).__defineGetter__('XMLDocument', function() {
					return holderObj;
				xmlTags.item(i).__defineGetter__('XMLDocument', function() {
		if(typeof fnLoad == 'function') fnLoad();
	load: function(fnLoad) {
		if(typeof document.all == 'undefined') {
			window.addEventListener('load', function() {
			}, true);
		else if(typeof fnLoad == 'function')
			window.onload = fnLoad;
To load, use oXMLLoader.load(Function fnLoad), where fnLoad() is the function to be called when all documents have been parsed.

Maybe later on I'll add extra support for rendering datasrc and such.

Happy coding!