$(document).ready(function(){
  showTime();
  setInterval(showTime, (60000*60*6));
  function showTime(){ 
	var today = new Date();
	var y=today.getFullYear()+"";
	var month=today.getMonth()+1+"";
	var t=today.getDate();
	if(today.getHours()<10){
		var h="0"+today.getHours()+":";
	}else{
		var h=today.getHours()+":";
	}
	if(today.getMinutes()<10){
		var m="0"+today.getMinutes()+":";
	}else{
		var m=today.getMinutes()+":";
	}
	if(today.getSeconds()<10){
		var s="0"+today.getSeconds();
	}else{
		var s=today.getSeconds();
	}
	var day = today.getDay();
	var weeks = new Array("星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六");
	var week = weeks[day];
  
	// $('.toptime').html("<b>"+h+m+s+"</b><span>"+y+month+t+" "+week+"</span>");
	$('.toptime').html("<span>"+y+"年"+month+"月"+t+"日"+"</span>");

  } 
})

$(function(){
	
	$(".etab_t ul li").click(function(){  
		$(this).siblings().removeClass('on').end().addClass('on');
		$(this).parents('.etab_t').siblings('.etab_m').hide();
		$(this).parents('.etab_t').siblings('.etab_m').eq($(this).index()).show();
	});
	
	$(".video_box i").click(function(){
		$(".video_box i").each(function(){
			$(this).show();
			$(this).siblings('video').trigger('pause');
		});
		$(this).hide();
		$(this).siblings('video').trigger('play');
	});
	
	$(".ttab_t ul li").click(function(){  
		$(this).siblings().removeClass('on').end().addClass('on');
		$(this).parents('.ttab_t').siblings('.ttab_m').removeClass('ttab_mshow');
		$(this).parents('.ttab_t').siblings('.ttab_m').eq($(this).index()).addClass('ttab_mshow');
	});

});