


// 属性设置 
var E_strIFaderTransType = 'reveal'; // 'reveal' | 'blend' 
var Filter_number = 23; // 滤镜种数 
var change_time = 3.000; // 滤镜转换过程为3.0秒延迟 
var wait_time = 5000; // 两种滤镜之间为5秒延迟

var obj_Timer; 
var count_temp = 0; //记录当前是第几幅图片 
var Img_arry = new Array(); //图片数组 
var E_ie4 = document.all?true:false; 
var E_nn4 = document.layers?true:false;

function Filt_set() //设置滤镜 
{ 
   if(!E_ie4 && !E_nn4) return;
   if(E_ie4) { 
     var theImg = document.all['idImgFading']; 
     if(theImg == null) return; 
     with(document.all['idImgFading']) { 
       style.filter = (E_strIFaderTransType == 'reveal')?'revealTrans':'blendTrans'; 
       style.filter.duration = change_time; 
       style.filter.transition = Filter_number; 
     } 
   } 
   use_Filter();
   obj_Timer = window.setInterval('use_Filter()',wait_time); 
}

function use_Filter() //滤镜的启动 
{ 
   if(E_ie4) { 
     with(document.all['idImgFading']) { 
       if(E_strIFaderTransType == 'reveal') { 
         filters(0).transition = Filter_number; 
       } 
       if(count_temp == (Img_arry.length - 1)) { 
         count_temp = -1; 
       } 
       count_temp++; 
       title = Img_arry[count_temp].sAlt; 
       parentElement.href = Img_arry[count_temp].command;
    document.all['idImgLink'].innerText=title;
    document.all['idImgLink'].href= Img_arry[count_temp].command;
    
       filters(0).apply(); 
       src = Img_arry[count_temp].sImgUrl; 
       filters(0).play();
     } 
   } 
   else if(E_nn4) { 
     if(count_temp == (Img_arry.length - 1)) { 
       count_temp = -1; 
     } 
     count_temp++; 
     document.images['idImgFading'].src = Img_arry[count_temp].sImgUrl; 
   } 
}

function obj_ClearTime() { 
   window.clearInterval(obj_Timer); 
} 
window.onunload = obj_ClearTime;//取消计时器，释放系统资源

function Img_obj(sImgUrl,command,sAlt,sTarget) 
{ 
   this.sImgUrl = (sImgUrl == null)?'':sImgUrl; 
   this.command = (command == null || command == '')?'/':command; 
   this.sAlt = (sAlt == null)?'':sAlt; 
   this.sTarget = (sTarget == null || sTarget == '')?'_blank':sTarget; 
} 

Img_arry[0] = new Img_obj('/upload/topadbanner/banner_1.jpg','http://sc.yongyao.net','','_blank'); 
Img_arry[1] = new Img_obj('/upload/topadbanner/banner_2.jpg','http://yy.yongyao.net','','_blank'); 
Img_arry[2] = new Img_obj('/upload/topadbanner/banner_3.jpg','/jayyt/jayyt.html','','_blank'); 
Img_arry[3] = new Img_obj('/upload/topadbanner/banner_4.jpg','/new/jbzc.aspx','','_blank'); 
Img_arry[4] = new Img_obj('/upload/topadbanner/banner_5.jpg','/new/xx.aspx','','_blank'); 


			function selectgjc(gjc)
			{ 
			if(gjc=="输入查询内容，点击右边按钮进入分类检索")
			{
			gjc='';
			}
			window.open("/new/selectnews.aspx?nr="+escape(gjc));
			}
			function selectypgjc(gjc)
			{ 
			if(gjc=="输入查询内容，点击右边按钮进入分类检索")
			{
			gjc='';
			}
			window.open("/new/search1.aspx?parm="+escape(gjc));
			}
			function selectbzgjc(gjc)
			{ 
			if(gjc=="输入查询内容，点击右边按钮进入分类检索")
			{
			gjc='';
			}
			window.open("/new/bz_search1.aspx?parm="+escape(gjc));
			}
				var objdiv;
			function showdiv(i)
			{  
				if(objdiv!=i)
			{
				var alldiv=document.getElementsByTagName("div");
				for(var j=0;j<alldiv.length;j++)
				{
					alldiv[j].style.display="none";
				}
				i.style.display="block";
				objdiv=i;
			}
				else
				{
				i.style.display="none";
				objdiv="";
			}
			}
			function show(i)
			{     
			if (i.style.display == "none") {   
			i.style.display = "";  
			}else{     
				i.style.display = "none"; 
			}     
				}
				
				/*
			function SubmitKeyClick(strvalue) 
			{    
			if (event.keyCode == 13) 
			{        
			event.keyCode=9;
			event.returnValue = false;
			selectbzgjc(strvalue); 
			}
			}
			*/
			
			
			
function SubmitKeyClick(button) 
{    
 if (event.keyCode == 13) 
 {        
  event.keyCode=9;
  event.returnValue = false;
  document.all[button].click(); 
 }
}
function gotdwytw()
{
	window.location.href="kstw.aspx?lb=&nr=#tdwytw";
}

		function showdivbz(obj)
		{
			var e=document.getElementById("shelp")
			var t=e.offsetTop;
			var l=e.offsetLeft;
			while(e=e.offsetParent)
			{
				t+=e.offsetTop;
				l+=e.offsetLeft;
			} 
			obj.style.position="absolute";
			obj.style.left=l;
			obj.style.top=t+20;
			
			if(obj.style.display=="none")
			{
				obj.style.display="block";
			}
			
		}
		
		function nonediv(objname)
		{
			document.getElementById(objname).style.display="none"
		}
function gozjdh()
{
	window.location.href="zjdh.aspx"
}
function checkinput()
{
	if(document.getElementById("Newtop1_txtyhm").value=="")
	{
		alert("提示：用户名不能为空！");
		document.getElementById("Newtop1_txtyhm").focus();
		return false;
	}
	
	if(document.getElementById("Newtop1_txtpassword").value=="")
	{
		alert("提示：密码不能为空！");
		document.getElementById("Newtop1_txtpassword").focus();
		return false;
	}
	
	/*
	if(document.getElementById("Newtop1_txtyzm").value=="")
	{
		alert("提示：验证码不能为空！");
		document.getElementById("Newtop1_txtyzm").focus();
		return false;
	}
	*/
	
	
}
function checkinputnew()
{
	if(document.getElementById("Topnew1_txtyhm").value=="")
	{
		alert("提示：用户名不能为空！");
		document.getElementById("Topnew1_txtyhm").focus();
		return false;
	}
	
	if(document.getElementById("Topnew1_txtpassword").value=="")
	{
		alert("提示：密码不能为空！");
		document.getElementById("Topnew1_txtpassword").focus();
		return false;
	}
	
	/*
	if(document.getElementById("Newtop1_txtyzm").value=="")
	{
		alert("提示：验证码不能为空！");
		document.getElementById("Newtop1_txtyzm").focus();
		return false;
	}
	*/
	
	
}