var xmlHttp var strSpanID function getProductName(str,strSpanID1) { strSpanID=strSpanID1; if (str.length==0) { document.getElementById(strSpanID).innerHTML=""; return; } xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?pn="+str; url=url+"&action=getProductName"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function getcheckEmail(str,strEmail,strSpanID1) { strSpanID=strSpanID1; if (str.length==0) { document.getElementById(strSpanID).innerHTML=""; return; } if (strEmail.length==0) { document.getElementById(strSpanID).innerHTML=""; return; } xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?pwd="+str; url=url+"&email="+strEmail; url=url+"&action=getcheckEmail"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged1; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function getGradeInfo(str,strSpanID1) { strSpanID=strSpanID1; xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?state="+str; url=url+"&action=getGradeInfo"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged1; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function getSubjectInfo(str,strState,strSpanID1) { strSpanID=strSpanID1; xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?grade="+str; url=url+"&state="+strState; url=url+"&action=getSubjectInfo"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged1; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function getStrandInfo(str,strState,strGrade,strSpanID1) { strSpanID=strSpanID1; xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?subject="+str; url=url+"&state="+strState; url=url+"&grade="+strGrade; url=url+"&action=getStrandInfo"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged1; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function getCurriculumDetails(strState,strGrade,strSubject,strStrand,strSpanID1) { strSpanID=strSpanID1; xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Your browser does not support AJAX!"); return; } var url="ajax_submit.asp"; url=url+"?state="+strState; url=url+"&grade="+escape(strGrade); url=url+"&subject="+escape(strSubject); url=url+"&Strand="+strStrand; url=url+"&action=getCurriculumDetails"; url=url+"&rdm="+Math.random(); xmlHttp.onreadystatechange=stateChanged1; xmlHttp.open("GET",url,true); xmlHttp.send(null); } function stateChanged() { if (xmlHttp.readyState==4) { document.getElementById(strSpanID).innerHTML=xmlHttp.responseText; if ((xmlHttp.responseText).length > 0) { document.getElementById("product_number").value = ''; } } } function stateChanged1() { if (xmlHttp.readyState==4) { document.getElementById(strSpanID).innerHTML=xmlHttp.responseText; } } function GetXmlHttpObject() { var xmlHttp=null; try { // Firefox, Opera 8.0+, Safari xmlHttp=new XMLHttpRequest(); } catch (e) { // Internet Explorer try { xmlHttp=new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { xmlHttp=new ActiveXObject("Microsoft.XMLHTTP"); } } return xmlHttp; }