//tab ad
function imgTab(ids,our,imgs){
	for(i=1;i<=our;i++){
		if (i==ids){
			document.getElementById("img"+i).src="images/tab"+i+".jpg";
			document.getElementById("imgAll").src=imgs;
		}else{
			document.getElementById("img"+i).src="images/taba"+i+".jpg";
		}
	}
}
//tab adx
function imgxTab(ids,our,imgs){
	for(i=1;i<=our;i++){
		if (i==ids){
			document.getElementById("img"+i).src="images/tabx"+i+".gif";
			document.getElementById("imgxAll").src=imgs;
		}else{
			document.getElementById("img"+i).src="images/tabx"+i+"b.gif";
		}
	}
}

/**************************_________(menu change)_________*************************
ע�⣺
<div id="mainLeft">
	...��֮�������һ��Ҫ�����ڵĸ�ʽ...
</div>

˵��
����˵�û���Ӳ˵�ʱ������˵�����t�ӣ���
1��
<div id="menua3" class="lMenuT"><a href="#">+ �γ�����</a></div>
����û���Ӳ˵��ġ�
2��
<div id="menua2" class="lMenuT" onclick="menuChange(2,4)">+ ��������</div>
        <div id="menub2" class="lMenuM none"><a href="#">�����γ�</a><a href="#">�����γ�</a><a href="#">�����γ�</a><a href="#">�����γ�</a><a href="#">�����γ�</a></div>
�������Ӳ˵���

������ڣ�<a href="#">+ �γ�����</a>   + ��������   ��һ����a��ǩһ��û�У�ע��a��ǩ�Ĵ�Сд��"href"Ҫ��Сд��д��
����ж�û��a��ǩ��href��������"</a><a"����ַ��е�"><"4�ж��м����Ӳ˵�

menuChange(ts,al)
ts����ǰ�ĵڼ�����˵�
al��һ���ж��ٸ���˵�
��HTMLԴ����Ӧ�ÿ������
**********************************************************************************/
	var a=0;
	var b=0;
	var speed=9;//
	function menuChange(ts,al)
	{
		for(var i=1;i<=al;i++)
		{
			if(document.getElementById("menua"+i).innerHTML.indexOf("href")==-1)
			{
				if(ts==i)
				{	
					ab=document.getElementById("menub"+i)
					if(ab.className=="lMenuM none")
					{
						arr=ab.getElementsByTagName("a");
						allHeight=27*arr.length;
						ab.className="lMenuM show";
						ab.style.height="0px";
						adHeight=setInterval("divHeight('menub'+"+i+","+allHeight+","+arr.length+",1)",1)
					}
				}else{
					ab=document.getElementById("menub"+i)
					if(document.getElementById("menub"+i).className=="lMenuM show")
					{
						arr=ab.getElementsByTagName("a");
						allHeight=27*arr.length;
						ab.style.height=allHeight+"px";
						b=allHeight;
						bdHeight=setInterval("divHeight('menub'+"+i+","+allHeight+","+arr.length+",2)",1)
					}
				}
			}
		}
	}
	function divHeight(ad,al,gs,ty)
	{
		if(ty==1){
			if(a<al){
			a+=speed;
			if(a>=al){a=al};
				document.getElementById(ad).style.height=a+"px";
			}else{
				clearInterval(adHeight)
				a=0
			}
		}else{
			if(b>0){
			b-=speed;
			if(b<0){b=0};
				document.getElementById(ad).style.height=b+"px";
			}else{
				b=0;
				document.getElementById(ad).className="lMenuM none";
				clearInterval(bdHeight);
			}
		}
	}