var xhr = false;

function createXMLHttpRequest() {
	if(window.XMLHttpRequest) {
		xhr = new XMLHttpRequest();
	}
	else if(window.ActiveXObject) {
		xhr = new ActiveXObject("Microsoft.XMLHTTP");
	}
}

function makeRequest(tid) {
	var id = tid;
	createXMLHttpRequest();
	xhr.onreadystatechange = showContents;
	xhr.open("GET", "allcomments.php?tid="+id, true);
	xhr.send(null);
	function showContents() {
	if(xhr.readyState == 4) {
		if(xhr.status == 200) {
			document.getElementById("sisalto"+id).innerHTML = xhr.responseText;
		}
	}
	}
}

