//<!CDATA[ 
function g(o){return document.getElementById(o);} 
/*function HoverLi(n){ 
//如果有N个标签,就将i<=N; 
//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
for(var i=1;i<=6;i++){g('tb_'+i).className='normaltab';g('tbc_0'+i).className='undis';}g('tbc_0'+n).className='dis';g('tb_'+n).className='hovertab'; 
} 
//如果要做成点击后再转到请将<li>中的onmouseover 改成 onclick; 
//]]>
*/



//<!CDATA[ 
function g(o){return document.getElementById(o);} 
/*function HoverLi(n){ 
//如果有N个标签,就将i<=N; 
//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
for(var i=1;i<=6;i++){g('tb_'+i).className='normaltab';g('tbc_0'+i).className='undis';}g('tbc_0'+n).className='dis';g('tb_'+n).className='hovertab'; 
} 
//如果要做成点击后再转到请将<li>中的onmouseover 改成 onclick; 
//]]>
*/
//edit by humen1//
function HoverLi(perfix,n,q){ 
//如果有N个标签,就将i<=N; 
//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
for(var i=1;i<=q;i++)
{g(perfix+'tb_'+i).className='normaltab';g(perfix+'tbc_'+i).className='undis';}
g(perfix+'tbc_'+n).className='dis';g(perfix+'tb_'+n).className='hovertab'; 
} 


function bHoverLi(perfix,n,q){ 
//如果有N个标签,就将i<=N; 
//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
for(var i=1;i<=q;i++)
{g(perfix+'btb_'+i).className='bnormaltab';g(perfix+'btbc_'+i).className='undis';}
g(perfix+'btbc_'+n).className='dis';g(perfix+'btb_'+n).className='bhovertab'; 
}


function cHoverLi(perfix,n,q)
{ 
	//如果有N个标签,就将i<=N; 
	//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
	for(var i=1;i<=q;i++)
	{
		g(perfix+'ctb_'+i).className='cnormaltab';
		g(perfix+'ctbc_'+i).className='undis';
	}
    g(perfix+'ctbc_'+n).className='dis';
	g(perfix+'ctb_'+n).className='chovertab'; 
} 


function dHoverLi(perfix,n,q)
{ 
	//如果有N个标签,就将i<=N; 
	//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
	for(var i=1;i<=q;i++)
	{
		g(perfix+'dtb_'+i).className='cnormaltab';
		g(perfix+'dtbc_0'+i).className='undis';
	}
    g(perfix+'dtbc_0'+n).className='dis';
	g(perfix+'dtb_'+n).className='chovertab'; 
}


function eHoverLi(perfix,n,q){ 
//如果有N个标签,就将i<=N; 

//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
for(var i=1;i<=q;i++)
{g(perfix+'etb_'+i).className='enormaltab';g(perfix+'etbc_'+i).className='undis';}
g(perfix+'etbc_'+n).className='dis';g(perfix+'etb_'+n).className='ehovertab'; 
}

 function gHoverLi(perfix,n,q)
{ 
	//如果有N个标签,就将i<=N; 
	//本功能非常OK,兼容IE7,FF,IE6;http://www.ii163.cn/ [北漂]系列 
	for(var i=1;i<=q;i++)
	{
		g(perfix+'gtb_'+i).className='gnormaltab';
		g(perfix+'gtbc_'+i).className='undis';
	}
    g(perfix+'gtbc_'+n).className='dis';
	g(perfix+'gtb_'+n).className='ghovertab'; 
} 


function switchTag()
{
	document.getElementById("m1_tbc_5").style.display="block";
	document.getElementById("m1_tb_5").className="hovertab";
	document.getElementById("m1_tb_6").className="normaltab";
		document.getElementById("m1_tb_4").className="normaltab";
	document.getElementById("m1_tb_1").className="normaltab";
		document.getElementById("m1_tb_3").className="normaltab";
	document.getElementById("m1_tb_2").className="normaltab";
	document.getElementById("m1_tbc_6").style.display="none";
		document.getElementById("m1_tbc_4").style.display="none";
			document.getElementById("m1_tbc_3").style.display="none";
				document.getElementById("m1_tbc_2").style.display="none";
					document.getElementById("m1_tbc_1").style.display="none";
	
		
} 
function setTab(name,cursel,n){
for(i=1;i<=n;i++){
var menu=document.getElementById(name+i);
var con=document.getElementById("con_"+name+"_"+i);
menu.className=i==cursel?"hover":"";
con.style.display=i==cursel?"block":"none";
}
}
