// JavaScript Document
var xmlHttp=false;
function createObject(){
	try{xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
	}catch(e){
		try{xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
		}catch(e2){}
		if(!xmlHttp && typeof XMLHttpRequest != "undefined"){
			try{xmlHttp =new XMLHttpRequest();
			}catch(e3){xmlHttp=false;}
		}
	}
}
function httpSetting(){
 if(xmlHttp.readyState == 4){
 	if(xmlHttp.status == 200 || xmlHttp.status == 0){
			InterValData(xmlHttp.responseText);
	}
 }
}
function httpSetting2(){
	var Ran= Math.round(Math.random()) * 2000 + 1000
 if(xmlHttp.readyState == 4){
 	if(xmlHttp.status == 200 || xmlHttp.status == 0){
		setTimeout("CL_Data('"+xmlHttp.responseText+"')",Ran)
	}else{
		CL_Data("服务器连接失败！请确认您的网络");
	}
 }
}

function getData(e,p){
	createObject();
	var url = "ajax.asp";
	 xmlHttp.open("post",url,true);
	 xmlHttp.onreadystatechange=httpSetting;
	 //xmlHttp.setRequestHeader("If-Modified-Since","0");
	 xmlHttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
	 xmlHttp.send(null);
	 return false
}

function InterValData(Txt){
		document.getElementById("HnewsList").innerHTML = Txt;
}
function CK_Data(v){
	createObject();
	var url="/ajax2.asp?TypeID="+v
	xmlHttp.open("post",url,true);
	xmlHttp.onreadystatechange=httpSetting2;
	xmlHttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
	 xmlHttp.send(null);
	 return false
}
function CL_Data(Txt){
	var OP =  document.getElementById("Alpha");
	var OL = document.getElementById("CKG");
	OP.style.display="none";
	OL.style.display ="none";
	alert(Txt)
}
function CK_Alpha(v){
	if(!document.getElementById("Alpha")){
			CrateAlpha();
		}
	var height=document.body.clientHeight;
	var OP =  document.getElementById("Alpha");
	var OL = document.getElementById("CKG");
	OP.style.display="";
	OL.style.display ="";
	CK_Data(v);
}
function CrateAlpha(){
	var o = document.body
	var str ='<div id="Alpha" style="height:1000px; background:#000; z-index:500; width:100%; position:absolute; top:0; left:0;filter:Alpha(Opacity=40);-moz-opacity:0.4; opacity:0.4;display:none"></div>' ;
		str+='<div id="CKG" style="position:absolute; left:50%; top:50%; width:95px; height:7px; z-index:1000;display:none"><div style="position:absolute; left:-50%; top:-50%; color:#fff; font-size:12px;">';
		str+='VPN系统检测中...<br /><img src="/Images/023.gif"  style="margin-top:3px;"/>';
		str+='</div></div>';
		//alert(o)
	o.innerHTML+=str;
}

