//创建xmlHttp对象 
function XmlPost(webFileUrl)
{
 var result = "";
 var xmlHttp;
 if   (window.XMLHttpRequest)   {   
	xmlHttp = new XMLHttpRequest();   
}
else if(window.ActiveXObject)   {   
	xmlHttp = new ActiveXObject("Microsoft.XMLHTTP"); 
} 
 xmlHttp.open("get", webFileUrl, false);
 xmlHttp.send(null);
 result = xmlHttp.responseText;
 return(result);
}
//动态显示html 
function displayCont(id,opty,title)
{ 
  window.document.getElementById("title").innerHTML = title;
  window.document.getElementById("ScrollerCont1001").innerHTML = XmlPost("/include/getList.asp?id=" + id + "&opty=" + opty);
}
//判断字符串是否为数字     //判断正整数 /^[1-9]+[0-9]*]*$/
function checkRate(strInput)
{
	var re = /^[0-9]+.?[0-9]*$/;   
	return re.test(strInput);
}  
//显示图片
function imgPicse(img)
{ 
 //alert(img);
 window.document.getElementById("modelStr").src = img;
}
//
function displayzz1(sm,sn)
{ 
 //alert(sm);
 window.document.getElementById("index2007").innerHTML = XmlPost("/include/getList.asp?id=" + sn + "&opty=1002");
 if(sm == "zz11")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz12").style.background = "none"; 
	window.document.getElementById("zz13").style.background = "none";
 }
 if(sm == "zz12")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz11").style.background = "none"; 
	window.document.getElementById("zz13").style.background = "none";
 }
 if(sm == "zz13")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz12").style.background = "none"; 
	window.document.getElementById("zz11").style.background = "none";
 } 
}
//
function displayzz2(sm,sn)
{ 
 //alert(img);
 window.document.getElementById("index2008").innerHTML = XmlPost("/include/getList.asp?id=" + sn + "&opty=1002");
 if(sm == "zz21")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz22").style.background = "none"; 
	window.document.getElementById("zz23").style.background = "none";
 }
 if(sm == "zz22")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz21").style.background = "none"; 
	window.document.getElementById("zz23").style.background = "none";
 }
 if(sm == "zz23")
 {
	window.document.getElementById(sm).style.background = "#DBBEBE";
    window.document.getElementById("zz22").style.background = "none"; 
	window.document.getElementById("zz21").style.background = "none";
 } 
}
