/*----子菜单联动开始----*/ function mover(object){ var mm=document.getElementById("m_"+object); mm.className="m_li_a"; var mdef=document.getElementById("m_1"); mdef.className="m_li"; var sdef=document.getElementById("s_1"); sdef.style.display="none"; var ss=document.getElementById("s_"+object); ss.style.display="block"; } function mout(object){ var mm=document.getElementById("m_"+object); mm.className="m_li"; var mdef=document.getElementById("m_1"); mdef.className="m_li_a"; var ss=document.getElementById("s_"+object); ss.style.display="none"; var sdef=document.getElementById("s_1"); sdef.style.display="block"; } /*----子菜单联动结束----*/ /*----------左侧级联菜单-----------*/ function switchmenu(menuid) { var subid = "#left_submenu_"+menuid; if($(subid).css("display")=="none"){ $(subid).show(); } else{ $(subid).hide(); } $("#ch_"+menuid+" a i").toggleClass("fa-plus").toggleClass("fa-minus"); } /*--时钟函数开始--*/ function tick() { var hours, minutes, seconds, xfile; var intHours, intMinutes, intSeconds; var today, theday; today = new Date(); function initArray(){ this.length=initArray.arguments.length for(var i=0;ili').not(":first").mouseenter(function () { $('#welcome').css('display','none'); $(this).find('ul').stop(false, true).slideDown(st); }).mouseleave(function () { $(this).find('ul').stop(false, true).slideUp(st); $('#welcome').css('display','block'); }); /*-----左侧栏目高亮------*/ if(typeof('xxx') == "undefined"){ var chID= "#ch_"+$pageInfo.channelID; if(chID) { if($(chID).parent(".left_submenu").parent("li").length>0) { $(chID).parent(".left_submenu").parent("li").addClass("current"); $(chID).parent(".left_submenu").show(); $(chID).addClass("subcurrent"); } else{ $(chID).addClass("current"); } } } /*-------世界地图---------*/ var world = document.getElementById("world"); if (location.protocol == "file:") { // var warningDiv = document.createElement("div"); // warningDiv.style.color = "red"; // document.body.insertBefore(warningDiv, world); // warningDiv.textContent = "error"; } world.addEventListener("load", function () { var doc = world.getSVGDocument(); var proall = doc.querySelectorAll("[cc=cn]"); for (var i = 0, len = proall.length; i < len; i++) { var pro = proall[i]; //或strongs.item(i) pro.style.fill = "#003d92"; pro.style.stroke = "white"; } var proall1 = doc.querySelectorAll("[cc=cn1]"); for (var i = 0, len = proall1.length; i < len; i++) { var pro1 = proall1[i]; //或strongs.item(i) pro1.style.fill = "#ea0012"; pro1.style.stroke = "white"; } // Alert the ISO3166 code of clicked countries doc.addEventListener("mouseover", function (e) { var target = e.target, title = target.getAttribute("title"), cc = target.getAttribute("cc"); if (cc) { var toolTip = "
" + title + "
"; $("body").append(toolTip); $("#tooltip").css({ "top" :(e.pageY+180) + "px", "left" :(e.pageX+700) + "px" }); } }); doc.addEventListener("mouseout", function (e) { $("#tooltip").remove(); }); doc.addEventListener("mousemove", function (e) { $("#tooltip").css({"left":(e.pageX+700)+"px","top":(e.pageY+180)+"px",}); }); }); /**************搜索框***************/ $('#cwesearch').find('img').bind('click',function(){$('#cwesearch').submit();}); });