    $(document).ready(function(){	
		
           $("#ta tr").mouseover(function(){
            $(this).addClass("over");
           });
           $("#ta tr").mouseout(function(){
            $(this).removeClass("over");
           });
		   
		 $("#ta2 tr").mouseover(function(){
            $(this).addClass("over");
           });
          $("#ta2 tr").mouseout(function(){
            $(this).removeClass("over");
           });
		   $(".ta tr").mouseover(function(){
            $(this).addClass("over");
           });
           $(".ta tr").mouseout(function(){
            $(this).removeClass("over");
           });
		   
		 $("table[id^='tb_banner']").mouseover(function(){
            $(this).addClass("over");
			
           });
          $("table[id^='tb_banner']").mouseout(function(){
            $(this).removeClass("over");
		
           });           
		    
		  //photo
		   var tabsize=$("div[id^='tab_']").length;
		 $("div[class^='diary_photo']>div[id^='tab_']").mouseover(function(){
						   
           var tabid1=$(this).attr("id");		  
		   var tabid2=tabid1.substring(4,5);			 
		 	
           tabswitch(tabid2, tabsize, 'tab', 'panel');
           }); 
		   $(".diary_photo2,.diary_photo3").mouseout(function(){
												
           tabswitch('0', tabsize, 'tab', 'panel');
           }); 
		   $(".newstab_ul>li").click(function()
			{  
			  $(".newstab_ul>li").find("a").removeClass("current");
			  $(this).find("a").addClass("current");
			});
		   
          });
	
	function tabswitch(active, number, tab_prefix, content_prefix) 
	{		
	for (var i=0; i <=number; i++) {$('#'+content_prefix+'_'+i.toString()).css("display","none");}
	$('#'+content_prefix+'_'+active).css("display","block");
	}
	 function tabswitch1(active, number, tab_prefix, content_prefix) {
	for (var i=1; i <=number; i++) {
	 document.getElementById(content_prefix+'_'+i.toString()).style.display="none";
  document.getElementById(tab_prefix+'_'+i.toString()).className = '';
	  }
	document.getElementById(content_prefix+'_'+active).style.display="block";
    document.getElementById(tab_prefix+'_'+active).className = 'current';	

	 }
