⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ajax.js

📁 BBWPS 宾馆管理系统 php+mysql
💻 JS
字号:
function Bin2Str(Binary){	try{		var axRs = new ActiveXObject('ADODB.RecordSet');		axRs.Fields.Append('Binary2String',201,1);		axRs.open();		axRs.addNew();		axRs(0).appendChunk(Binary);		axRs.update();		var Result = axRs(0).value;		axRs.Close();		return Result;	}catch(e){		return null;	}}function startRequest(xmlHttp,reqURL,showContent) {		xmlHttp.open('GET',reqURL,'true');		xmlHttp.onreadystatechange = function handleStateChange(){			if(xmlHttp.readyState == 2) {		     document.getElementById(showContent).innerHTML = "正在载入......";		  }		  if(xmlHttp.readyState == 4) {			  if(xmlHttp.status == 200) {			  	var conz = Bin2Str(xmlHttp.responseBody)				  var allcon =  conz;				  document.getElementById(showContent).innerHTML = allcon;			 }		  }		};		xmlHttp.send(null);	}	function selectRequest(xmlHttp,reqURL,showContent) {		var selects = document.getElementById(showContent);		xmlHttp.open('GET',reqURL,'true');		selects.options.length=0;		xmlHttp.onreadystatechange = function handleStateChange(){			if(xmlHttp.readyState == 2) {		     document.getElementById(showContent).innerHTML = "正在载入......";		  }		  if(xmlHttp.readyState == 4) {			  if(xmlHttp.status == 200) {			  	var cons = Bin2Str(xmlHttp.responseBody);				  var allcon =  cons;				  var outString = allcon.split(";");				  var option =new Option("--请选择--","");				  selects.add(option);				  for(var i=0;i<outString.length-1;i++){				    var tmp = outString[i].split(",");				    var option =new Option(tmp[1],tmp[0]);				    try{				  	  selects.add(option);				    }catch(e){}				 }			 }		  }		};		xmlHttp.send(null);	}	function show(c_Str){   if(document.all(c_Str).style.display=='none'){     document.all(c_Str).style.display='block'   }else{     document.all(c_Str).style.display='none'   }  }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -