|
Server : Apache/2.2.2 (Fedora) System : Linux App1.pathumtani.go.th 2.6.20-1.2320.fc5smp #1 SMP Tue Jun 12 19:40:16 EDT 2007 i686 User : apache ( 48) PHP Version : 5.2.9 Disable Function : NONE Directory : /home/pathumthani_integration/pathumthani_drug/administrator/ |
Upload File : |
function CreateXmlHttp(){
//Creating object of XMLHTTP in IE
try {
XmlHttp = new ActiveXObject("Msxml2.XMLHTTP");
}
catch(e){
try{
XmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
}
catch(oc) {
XmlHttp = null;
}
}
//Creating object of XMLHTTP in Mozilla and Safari
if(!XmlHttp && typeof XMLHttpRequest != "undefined") {
XmlHttp = new XMLHttpRequest();
}
} // end function CreateXmlHttp
function chgAmphur(e, defa_v, tambon) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.chgamphur.php?PvID="+e+"&DfVal="+defa_v, true);
XmlHttp.onreadystatechange=function() {//alert("Aussy!!");
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("lblAmphur").innerHTML = res;
chgTambon(defa_v, tambon);
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}
function chgTambon(e, defa_v) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.chgtambon.php?TbID="+e+"&DfVal="+defa_v, true);
XmlHttp.onreadystatechange=function() {
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("lblTambon").innerHTML = res;
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}
function chgMoo(e, defa_v) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.chgmoo.php?MooID="+e+"&DfVal="+defa_v, true);
XmlHttp.onreadystatechange=function() {
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("lblMoo").innerHTML = res;
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}
function chgMooname(e, defa_v) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.chgmooname.php?MooID="+e+"&DfVal="+defa_v, true);
XmlHttp.onreadystatechange=function() {
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("lblMooname").innerHTML = res;
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}
function showPoint(e) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.show_other.php?typeID="+e, true);
XmlHttp.onreadystatechange=function() {
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("show_point").innerHTML = res;
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}
function showGpoint(e) {
if ( e ) {
CreateXmlHttp();
XmlHttp.open("get", "ajax/ajax.show_gpoint.php?pointID="+e, true);
XmlHttp.onreadystatechange=function() {
if (XmlHttp.readyState==4) {
if (XmlHttp.status==200) {
var res = XmlHttp.responseText; //alert(res);
document.getElementById("Gpoint").innerHTML = res;
} else if (XmlHttp.status==404) {
alert("ไม่สามารถทำการดึงข้อมูลได้");
} else {
alert("Error : "+XmlHttp.status);
}
}
};
XmlHttp.send(null);
}
}