// JavaScript Document
function menuFix() {
	var sfEls = document.getElementById("k_globallink").getElementsByTagName("li");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		sfEls[i].onMouseDown=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		sfEls[i].onMouseUp=function() {
		this.className+=(this.className.length>0? " ": "") + "sfhover";
		}
		sfEls[i].onmouseout=function() {
		this.className=this.className.replace(new RegExp("( ?|^)sfhover\\b"), 

"");
		}
	}
}

function doClick(o){
	 o.className="navdt";
	 var j;
	 var id;
	 var e;
	 for(var i=1;i<=2;i++){
	   id ="nav"+i;
	   j = document.getElementById(id);
	   e = document.getElementById("sub"+i);
	   if(id != o.id){
	   	 j.className="navdt2";
	   	 e.style.display = "none";
	   }else{
			e.style.display = "block";
	   }
	 }
	 }

if (top.location !== self.location) {
top.location=self.location;
}

//自动切换
var cur_index=1
var num=3  //标签个数
var settime
function GetObj(objName){
if(document.getElementById){
   return eval('document.getElementById("' + objName + '")');
}else if(document.layers){
   return eval("document.layers['" + objName +"']");
}else{
   return eval('document.all.' + objName);
}
}
function change_Menu(index){
for(var i=1;i<=num;i++){/* 最多支持8个标签 */
   if(GetObj("con"+i)&&GetObj("m"+i)){
    GetObj("con"+i).style.display = 'none';
    GetObj("m"+i).className = "menu"+i+"Off";
   }
}
if(GetObj("con"+index)&&GetObj("m"+index)){
   GetObj("con"+index).style.display = 'block';
   GetObj("m"+index).className = "menu"+index+"On";
}
cur_index=index
if(cur_index<num){
    cur_index++
   }
else{
     cur_index=1
   }
settime=setTimeout("change_Menu(cur_index)",30000)//延迟时间
  
}
function Menu(c_index){
clearTimeout(settime)
change_Menu(c_index)
}    


//总有自适应