// JavaScript Document
$(document).ready(function(){

$('.CPDTnewProduct').eq(0).show();
		$('#CPDTnewProductJS').find('a').mousemove(function() {
			var n=$('#CPDTnewProductJS').find('a').index(this);
			$('#CPDTnewProductJS').find('a').removeClass('CPDTnewProductJSa');
			$(this).addClass('CPDTnewProductJSa');
			$('.CPDTnewProduct').hide();
			$('.CPDTnewProduct').eq(n).show();
		});



$(".eightTyphoonBox").eq(0).show();
			$("#img").find("a").mouseover(function(){
				var qhTab=$("#img").find("a").index(this);
				$(".eightTyphoonBox").hide();
				$(".eightTyphoonBox").eq(qhTab).css("display","block");
				return false;
		
		});


$(".oceanUtilityDataBoxRight").eq(0).show();
			$("#oceanUtilityData").find("a").mouseover(function(){
				var qhTab=$("#oceanUtilityData").find("a").index(this);
				$(".oceanUtilityDataBoxRight").hide();
				$(".oceanUtilityDataBoxRight").eq(qhTab).css("display","block");
				return false;
		
		});



$(".oceanKnowledgeImg").eq(0).show();
			$("#oceanKnowledgeimg").find("a").mouseover(function(){
				var qhTab=$("#oceanKnowledgeimg").find("a").index(this);
				$(".oceanKnowledgeImg").hide();
				$(".oceanKnowledgeImg").eq(qhTab).css("display","block");
				return false;
		
		});



$('.oceanUtilityData').attr('id','rxl');

$(".oceanWeatherBoxImg").eq(0).show();
			$("#oceanWeatherBox").find("a").mouseover(function(){
				var qhTab=$("#oceanWeatherBox").find("a").index(this);
				$(".oceanWeatherBoxImg").hide();
				$(".oceanWeatherBoxImg").eq(qhTab).css("display","block");
				return false;
		
		});




	$(".importanceOceanWeatherAffairContent").eq(0).show();
	$("#importanceOcean").find("a").mouseover(function(){
		var qhTab=$("#importanceOcean").find("a").index(this);
		$(".importanceOceanWeatherAffairContent").hide();
		$(".importanceOceanWeatherAffairContent").eq(qhTab).css("display","block");
		return false;
	
	});





$(".boHaiSea").eq(0).show();
			$("#boHaiSeaBoxUl").find("a").mouseover(function(){
				var qhTab=$("#boHaiSeaBoxUl").find("a").index(this);
				$(".boHaiSea").hide();
				$(".boHaiSea").eq(qhTab).css("display","block");
				return false;
		
		});


$(".weatherVideoBoxImage").eq(0).show();
			$("#cropWetherList").find("li").click(function(){
				var qhTab=$("#cropWetherList").find("li").index(this);
				$(".weatherVideoBoxImage").hide();
				$(".weatherVideoBoxImage1").hide();
				$("#weatherVideoForm").hide();
				$(".weatherVideoBoxImage").eq(qhTab).css("display","block");
				return false;
		
		});
		
		

			$("#cropWetherList").find("h5").click(function(){
				$("#weatherVideoForm").css("display","block");
				return false;
		
		});

		
			$("#weatherVideoForm").find("input").click(function(){
				var qhTab=$("#weatherVideoForm").find("input").index(this);
				$(".weatherVideoBoxImage1").hide();
				$(".weatherVideoBoxImage").hide();
				$(".weatherVideoBoxImage1").eq(qhTab).css("display","block");
				return false;
		
		});
		
		
		$('.preventionVideoBox').find('dl:even').attr('style','float:right');
		$('.VideoBox').find('dl:even').attr('style','float:right');

        $('.todayLiving').find('dl:even').attr('style','float:right');


		$(".VideoContent").eq(0).show();
			$("#VideoContent").find("a").mouseover(function(){
				var qhTab=$("#VideoContent").find("a").index(this);
				$(".VideoContent").hide();
				$(".VideoContent").eq(qhTab).css("display","block");
				return false;
		
		});
			
			
		//右边栏的‘热点专题’的JS
		$('.topicesBox').eq(0).show();
		$('#topicsNav').children('li').mousemove(function() {
			var n=$('#topicsNav').children('li').index(this);
			$('#topicsNav').children('li').removeClass('move')
			$(this).addClass('move');
			$('.topicesBox').hide();
			$('.topicesBox').eq(n).show();
		});
	
		//隐藏‘未来6小时预报’JS
		$('.contraction').toggle(
			function() {
				$('#forecastID').slideUp();
				$(this).attr('src','images/jia01.gif')
			},
			function() {
				$('#forecastID').slideDown();
				$(this).attr('src','images/jian02.gif')
			}
		)	
		$('.contraction2').toggle(
			function() {
				$('#futureForecastBox').slideUp();
				$(this).attr('src','images/jia01.gif')
			},
			function() {
				$('#futureForecastBox').slideDown();
				$(this).attr('src','images/jian02.gif')
			}
)	
		
		
		//天气预报JS--------------------begin
		$('#weatherClickYubao').toggle(
			function() {
				$('#weatherYubao2').slideDown();
				$(this).html('关闭未来4-7天天气预报');
				return false;
			},
			function() {
				$('#weatherYubao2').slideUp();
				$(this).html('查看未来4-7天天气预报');
				return false;
			}
		)	
		//天气预报JS--------------------end
		
		
		$('.weatherClimeNewsBox').eq(0).show();
		$('#weatherClimeNewsNav').children('li').mousemove(function() {
			var n=$('#weatherClimeNewsNav').children('li').index(this);
			$('#weatherClimeNewsNav').children('li').removeClass('move')
			$(this).addClass('move');
			$('.weatherClimeNewsBox').hide();
			$('.weatherClimeNewsBox').eq(n).show();
		});
		
		$('#subjectSelect').find(":input").eq(0).click(function() {
				$('.subjectSelect1').show();
				$('.subjectSelect2').hide();
				});
				$('#subjectSelect').find(":input").eq(1).click(function() {
				$('.subjectSelect2').show();
				$('.subjectSelect1').hide();
				});

	
})


function showhidden(id,i){
		var select_obj=document.getElementsByTagName("select");
		if(i==1){
			document.getElementById(id).style.display="";
		}else{
			document.getElementById(id).style.display="none";
		}
}







