/*name: AjaxSend()descript: Comunicate with serverparams: url (path to ajax handler script); id (tag with id to update$)return: update id innerHTML.*/function AjaxSend(url, id){	var httpRequest;    if (window.XMLHttpRequest) { // Mozilla, Safari, ...        httpRequest = new XMLHttpRequest();        if (httpRequest.overrideMimeType) {            httpRequest.overrideMimeType('text/xml');        }    } else if (window.ActiveXObject) { // IE        try {            httpRequest = new ActiveXObject("Msxml2.XMLHTTP");        } catch (e) {            try {                httpRequest = new ActiveXObject("Microsoft.XMLHTTP");            } catch (e) {}        }    }    if (!httpRequest) {        alert('Giving up :( Cannot create an XMLHTTP instance');        return false;    }        	httpRequest.onreadystatechange = function() { alertContents(httpRequest, id); };    httpRequest.open('GET', url, true);    httpRequest.send(null);	return true;}function alertContents(httpRequest, id) {    if (httpRequest.readyState == 4) {        if (httpRequest.status == 200) {            document.getElementById(id).innerHTML = httpRequest.responseText;        } else {            alert('There was a problem with the request.');        }    }}/*name: AjaxSend()descript: Comunicate with server with no returnsparams: url (path to ajax handler script);*/function AjaxSend2(url, nexturl){	var httpRequest;    if (window.XMLHttpRequest) { // Mozilla, Safari, ...        httpRequest = new XMLHttpRequest();        if (httpRequest.overrideMimeType) {            httpRequest.overrideMimeType('text/xml');        }    } else if (window.ActiveXObject) { // IE        try {            httpRequest = new ActiveXObject("Msxml2.XMLHTTP");        } catch (e) {            try {                httpRequest = new ActiveXObject("Microsoft.XMLHTTP");            } catch (e) {}        }    }    if (!httpRequest) {        alert('Giving up :( Cannot create an XMLHTTP instance');        return false;    }        	httpRequest.onreadystatechange = function() { alertContents2(httpRequest, nexturl); };    httpRequest.open('GET', url, true);    httpRequest.send(null);	return true;}function alertContents2(httpRequest, nexturl) {    if (httpRequest.readyState == 4) {        if (httpRequest.status == 200) {            window.location = nexturl;        } else {            alert('There was a problem with the request.');        }    }}/*name: AjaxSend()descript: Comunicate with serverparams: url (path to ajax handler script); id (tag with id to update$)return: update id innerHTML.*/function AjaxSend3(url, openUrl){	var httpRequest;    if (window.XMLHttpRequest) { // Mozilla, Safari, ...        httpRequest = new XMLHttpRequest();        if (httpRequest.overrideMimeType) {            httpRequest.overrideMimeType('text/xml');        }    } else if (window.ActiveXObject) { // IE        try {            httpRequest = new ActiveXObject("Msxml2.XMLHTTP");        } catch (e) {            try {                httpRequest = new ActiveXObject("Microsoft.XMLHTTP");            } catch (e) {}        }    }    if (!httpRequest) {        alert('Giving up :( Cannot create an XMLHTTP instance');        return false;    }        alert(url);	httpRequest.onreadystatechange = function() { alertContents3(httpRequest, openUrl); };    httpRequest.open('GET', url, true);    httpRequest.send(null);	return true;}function alertContents3(httpRequest, openUrl) {    if (httpRequest.readyState == 4) {        if (httpRequest.status == 200) {        	//alert(document.getElementById('showData').innerHTML);        	 //window.open (openUrl, "mywindow", "menubar=0,resizable=1,width=310,height=260");        	 alert(httpRequest.responseText);			 	var obj = document.getElementById('showData');			 	var obj2 = document.getElementById('showData2');			 	/*obj2.style.width = "500px";			 	obj2.style.height = "500px";			 	obj2.style.display = "block";			 	obj2.style.position = "absolute";			 	obj2.style.top = "0px";			 	obj2.style.left = "0px";			 	obj2.style.background = "#000";			 	obj.style.display = "block";			 	obj.style.position = "absolute";			 	obj.style.top = "0px";			 	obj.style.left = "0px";			 	obj.innerHTML = '';			 	*/			 	var bbbbbb = '<img src="'+openUrl+'" />';			 	showThumb(bbbbbb);        	         } else {            alert('There was a problem with the request.');        }    }}
