// define XMLHttpRequest function if it doesn't exist. This is a workaround to allow calling of either XMLHttpRequest object (for browsers that support) or ActiveXObject for browsers which fo not (i.e. IE6)
if (typeof XMLHttpRequest == 'undefined') {
	window.XMLHttpRequest = function() {
		return new ActiveXObject('Microsoft.XMLHTTP');
	}
}

function showDocument(uri, targetDivName){
  	var xmlObj = new XMLHttpRequest();
  	xmlObj.onreadystatechange = function(){ 
		if(xmlObj.readyState == 4){
			document.getElementById(targetDivName).innerHTML = xmlObj.responseText;
		}
	}
    xmlObj.open('GET', uri, true); 
    xmlObj.send('');    
}