/********热门播客、热门相册********/
function nTabs(thisObj,Num){
if(thisObj.className == "active")return;
var tabObj = thisObj.parentNode.id;
var tabList = document.getElementById(tabObj).getElementsByTagName("li");
for(i=0; i <tabList.length; i++)
{
  if (i == Num)
  {
   thisObj.className = "active"; 
      document.getElementById(tabObj+"_Content"+i).style.display = "block";
  }else{
   tabList[i].className = "normal"; 
   document.getElementById(tabObj+"_Content"+i).style.display = "none";
  }
} 
}

/********热门博客排行********/
function scrollDoor(){
}
scrollDoor.prototype = {
 sd : function(menus,divs,openClass,closeClass){
  var _this = this;
  if(menus.length != divs.length)
  {
   alert("菜单层数量和内容层数量不一样!");
   return false;
  }    
  for(var i = 0 ; i < menus.length ; i++)
  { 
   _this.$(menus[i]).value = i;    
   _this.$(menus[i]).onmouseover = function(){
     
    for(var j = 0 ; j < menus.length ; j++)
    {      
     _this.$(menus[j]).className = closeClass;
     _this.$(divs[j]).style.display = "none";
    }
    _this.$(menus[this.value]).className = openClass; 
    _this.$(divs[this.value]).style.display = "block";    
   }
  }
  },
 $ : function(oid){
  if(typeof(oid) == "string")
  return document.getElementById(oid);
  return oid;
 }
}
/*window.onload = function(){
 var SDmodel = new scrollDoor();
 SDmodel.sd(["m01","m02","m03","m04"],["c01","c02","c03","c04"],"sd01","sd02");
 SDmodel.sd(["mm01","mm02","mm03","mm04"],["cc01","cc02","cc03","cc04"],"sd01","sd02");
 SDmodel.sd(["mmm01","mmm02","mmm03","mmm04"],["ccc01","ccc02","ccc03","ccc04"],"sd01","sd02");
}*/

/********推荐博主********/
function g(o){return document.getElementById(o);}
function HoverLi(n){
//如果有N个标签,就将i<=N;
//本功能非常OK,兼容IE7,FF,IE6;http://www.xiaogezi.cn/ [小鸽子]系列
for(var i=1;i<=3;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;
//]]>



function doHiddenObject(obj){
	if(obj==null)return;
	document.getElementById(obj).style.display="none";
}
function doShowObject(obj){
	if(obj==null)return;
	document.getElementById(obj).style.display="";
}
function doSwitchDiv(obj_id){
	if(obj_id=='title_teacher_blog'){
		doShowObject('title_teacher_blog');
		doHiddenObject('title_student_blog');
		doHiddenObject('title_parent_blog');
	}else if(obj_id=='title_student_blog'){
		doShowObject('title_student_blog');
		doHiddenObject('title_teacher_blog');
		doHiddenObject('title_parent_blog');
	}else if(obj_id=='title_parent_blog'){
		doShowObject('title_parent_blog');
		doHiddenObject('title_student_blog');
		doHiddenObject('title_teacher_blog');
	}
}	