	function MM_swapImgRestore() { 
	  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
	}
	function MM_preloadImages() { 
	  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
	    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
	    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
	}
	function MM_findObj(n, d) { 
	  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
	    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
	  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
	  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
	  if(!x && d.getElementById) x=d.getElementById(n); return x;
	}
	function MM_swapImage() { 
	  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
	   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
	}
	function overHeader(obj, ind, num){
		var tmpObj = obj;
		for(i=ind;i<num;i++){
			tmpObj = tmpObj.nextSibling;
			tmpObj.id='ce_zb';
		}
		tmpObj = obj;
		for(i=2;i<=ind;i++){
			tmpObj = tmpObj.previousSibling;
			tmpObj.id='ce_zb';
		}
		obj.id='ce_za';
		
		var tmpObj2 = document.getElementById('more_id').parentNode;
		tmpObj = obj.parentNode.nextSibling;
		for(i=1;i<=num;i++){
			if(i!=ind){
				tmpObj.style.display='none';
				tmpObj2.style.display='none';
			}else{
				tmpObj.style.display='block';
				tmpObj2.style.display='block';
			}
			tmpObj = tmpObj.nextSibling;
			tmpObj2 = tmpObj2.nextSibling;
		}
	}
//查看公告
	function viewDetailGG(btn, did){
		var detail = Ext.get(did).dom.innerText;
		viewDetail(btn, detail, '查看内容');
	}
	function viewDetailGroup(btn, did){
		var detail = Ext.get(did).dom.innerText;
		viewDetail(btn, detail, '${system.groupTea}介绍', 780, 560);
	}
//切换图层
	function showTip(str){
		if(document.getElementById(str).style.display == "none")
		document.getElementById(str).style.display = "block";
		else document.getElementById(str).style.display = "none";
	}
//首页显示当前、隐藏其他图层
	function showTip_index(str){
		var a =  new Array('jys','xqxz','kjg','tsg','xxs','grkj');
		for(i=0;i<a.length;i++){
			if(str==a[i])	document.getElementById(a[i]).style.display = "block";
			else	document.getElementById(a[i]).style.display = "none";
		}
	}
//教研室、兴趣小组、学习室 jquery 渐入渐出效果
	function j_showDiv(div,type){
		var obj = $('#'+div);
		obj.animate({
			height:type , opacity: type
		}, "slow");
	}
//教研室、兴趣小组、学习室 jquery 渐出效果
	function j_showOrDiv(div,type){
		var obj = $('#'+div);
		obj.animate({
			height:'toggle' , opacity: type
		}, "slow");
	}
//教研室、兴趣小组、学习室 最大化、还原窗口
	function maxDiv(str){
		var div = document.getElementById(str);
		var img = document.getElementById(str+"_max");
		if(img.alt!="最大化"){
			refreshWin(str,true);
			div.style.width = 872;
			div.style.height = 468;
			div.style.left = "50%";
			div.style.top = 0;
			img.alt = "最大化";
			img.src = "../groups_1/image/max_icon.gif";
		}else{
			refreshWin(str,true);
			div.style.width = 1048;
			div.style.height = 630;
			div.style.left = 415;
			div.style.top = 0;
			img.alt = "还原";
			img.src = "../groups_1/image/resize_icon.gif";
		}
	}
//教研室、兴趣小组、学习室刷新窗口
	function refreshWin(str,tf){
		var ifm = document.frames[str+"I"];
		var href = document.frames[str+"I"].location.href;
		var img = document.getElementById(str+"_max");
		if(tf){
			if(img.alt!="最大化"){
				ifm.location = href.replace("&win=max","&win=min");
			}else{
				if(href.indexOf('&win=min')!=-1) href = href.replace('&win=min','&win=max'); 
				if(href.indexOf('&win=max')==-1) href = href+"&win=max";
				ifm.location = href;
			}
		}else{
			if(img.alt!="最大化"){
				if(href.indexOf('&win=min')!=-1) href = href.replace('&win=min','&win=max'); 
				if(href.indexOf('&win=max')==-1) href = href+"&win=max";
				ifm.location = href;
			}else{
				ifm.location = href.replace("&win=max","&win=min");
			}
		} 
	}
//教研室、兴趣小组显示当前、隐藏其他图层
	function showTip_group(str){
		var a =  new Array('memberlist','resTip','blogTip','boardTip','discussTip');//map_zmout
		if(document.getElementById(str).style.display == "none"){
			for(i=0;i<a.length;i++){
				if(str==a[i])	document.getElementById(a[i]).style.display = "block";
				else	document.getElementById(a[i]).style.display = "none";
			}
			j_showOrDiv('roominfo','hide');
			j_showOrDiv('personalinfo','hide');
			//roominfo.hide();
			//personalinfo.hide();
		}
		else document.getElementById(str).style.display = "none";
		
	}
//学习室显示当前、隐藏其他图层
	function showTip_course(str){
		var a =  new Array('memberlist','boardTip','discussTip','courseTip','homeworkTip','contestTip');//map_zmout
		if(document.getElementById(str).style.display == "none"){
			for(i=0;i<a.length;i++){
				if(str==a[i])	document.getElementById(a[i]).style.display = "block";
				else	document.getElementById(a[i]).style.display = "none";
			}
			j_showOrDiv('roominfo','hide');
			j_showOrDiv('personalinfo','hide');
			//roominfo.hide();
			//personalinfo.hide();
		}
		else document.getElementById(str).style.display = "none";
		
	}
//教研室、兴趣小组iframe显示当前、隐藏其他图层
	function showIframe_group(str,url){
		var iframe = document.getElementById(str);
		var iframeI = document.getElementById(str+'I');
		var img = document.getElementById(str+"_max");
		if(img!=null&&img.alt!="最大化") url += "&win=max";
		else url += "&win=min";
		if(iframe.style.display == "none"&&iframeI.src!=url) iframeI.src = url;
		showTip_group(str);
	}
//教研室、兴趣小组iframe显示当前、隐藏其他图层
	function showIframe_group1(str,url){
		var iframe = document.getElementById(str);
		var iframeI = document.getElementById(str+'I');
		if(iframe.style.display == "none"&&iframeI.src!=url) iframeI.src = url;
		showTip_group(str);
	}
//学习室iframe显示当前、隐藏其他图层
	function showIframe_course(str,url){
		var iframe = document.getElementById(str);
		var iframeI = document.getElementById(str+'I');
		if(iframe.style.display == "none"&&iframeI.src!=url) iframeI.src = url;
		showTip_course(str);
	}
//显示图层
	function openTip(str){
		document.getElementById(str).style.display = "block";
	} 
//鼠标位置显示层	
	function openTip1(str,x,y){
		if(x==null)x=2;
		if(y==null)y=-2;
		document.getElementById(str).style.display = "block";
		document.getElementById(str).style.left=event.x+x;
		document.getElementById(str).style.top=event.y+y; 
		document.getElementById(str).position="absolute"; 
	}
//隐藏图层
	function closeTip(str){
		document.getElementById(str).style.display = "none";
	}
//显示导航名称
	function showName(str){
		document.getElementById("showName").innerText = str;
	} 
//隐藏导航名称
	function closeName(){
		document.getElementById("showName").innerText = "请选择地图";
	}

