﻿(function(a){a.fn.lazyload=function(d){var b={threshold:0,failurelimit:0,event:"scroll",effect:"show",container:window};d&&a.extend(b,d);var e=this;"scroll"==b.event&&a(b.container).bind("scroll",function(){var c=0;e.each(function(){if(!a.belowthefold(this,b)&&!a.rightoffold(this,b))a(this).trigger("appear");else if(c++>b.failurelimit)return false});var g=a.grep(e,function(f){return!f.loaded});e=a(g)});return this.each(function(){var c=this;a(c).attr("original",a(c).attr("src"));if("scroll"!=b.event|| a.belowthefold(c,b)||a.rightoffold(c,b)){b.placeholder?a(c).attr("src",b.placeholder):a(c).removeAttr("src");c.loaded=false}else c.loaded=true;a(c).one("appear",function(){this.loaded||a("<img />").bind("load",function(){a(c).hide().attr("src",a(c).attr("original"))[b.effect](b.effectspeed);c.loaded=true}).attr("src",a(c).attr("original"))});"scroll"!=b.event&&a(c).bind(b.event,function(){c.loaded||a(c).trigger("appear")})})};a.belowthefold=function(d,b){return(b.container===undefined||b.container=== window?a(window).height()+a(window).scrollTop():a(b.container).offset().top+a(b.container).height())<=a(d).offset().top-b.threshold};a.rightoffold=function(d,b){return(b.container===undefined||b.container===window?a(window).width()+a(window).scrollLeft():a(b.container).offset().left+a(b.container).width())<=a(d).offset().left-b.threshold};a.extend(a.expr[":"],{"below-the-fold":"$.belowthefold(a, {threshold : 0, container: window})","above-the-fold":"!$.belowthefold(a, {threshold : 0, container: window})", "right-of-fold":"$.rightoffold(a, {threshold : 0, container: window})","left-of-fold":"!$.rightoffold(a, {threshold : 0, container: window})"})})(jQuery); jQuery(".topmenu").ready(function(){$("#topmenu li a").wrapInner('<span class="out"></span>').append('<span class="bg"></span>');$("#topmenu li a").each(function(){$('<span class="over">'+$(this).text()+"</span>").appendTo(this)});$("#topmenu li a").hover(function(){$(".out",this).stop().animate({top:"40px"},250);$(".over",this).stop().animate({top:"0px"},250);$(this).parent().hasClass("topmenu_status")||$(this).parent().hasClass("current-cat")||$(this).parent().hasClass("current_page_item")||$(".bg", this).stop().animate({top:"0px"},100)},function(){$(".out",this).stop().animate({top:"0px"},250);$(".over",this).stop().animate({top:"-40px"},250);$(this).parent().hasClass("topmenu_status")||$(this).parent().hasClass("current-cat")||$(this).parent().hasClass("current_page_item")||$(".bg",this).stop().animate({top:"-40px"},100)})});var goto_top_type=-1,goto_top_itv=0; function goto_top_timer(){var a=goto_top_type==1?document.documentElement.scrollTop:document.body.scrollTop;a-=Math.ceil(a*15/100);if(a<0)a=0;if(goto_top_type==1)document.documentElement.scrollTop=a;else document.body.scrollTop=a;if(a==0){clearInterval(goto_top_itv);goto_top_itv=0}} function goto_top(){if(goto_top_itv==0){goto_top_type=document.documentElement&&document.documentElement.scrollTop?1:document.body&&document.body.scrollTop?2:0;if(goto_top_type>0)goto_top_itv=setInterval("goto_top_timer()",50)}}jQuery("#qq").ready(function(){jQuery("#qq").html(taotao)}); $(function(){$("#tabtags > li").mouseover(function(){if(!$(this).hasClass("selected")){$("#tabtags > li").removeClass("selected");$(this).addClass("selected");$("#tabtagContentALL dl").hide();$("#tabtagContentALL dl:eq("+$("#tabtags > li").index(this)+")").show()}})});var bulletinContent=[],bulletinIndex=0,changeDelay=5E3,scrollDelay=20,changeID,scrollID,maxLines=1; jQuery(".callboard").ready(function(){bulletinContent=document.getElementById("bulletinBoard").getElementsByTagName("div").item(0).innerHTML.split("\\n");document.getElementById("bulletinBoard").style.height=maxLines*20+"px";SetBulletin();changeID=setInterval("ChangeBulletin()",changeDelay)}); function ChangeBulletin(){SetBulletin();bulletinIndex++;bulletinIndex%=bulletinContent.length;document.getElementById("bulletinBoard").scrollTop=0;clearInterval(scrollID);scrollID=setInterval("ScrollBulletin()",scrollDelay)}function ScrollBulletin(){document.getElementById("bulletinBoard").scrollTop++;document.getElementById("bulletinBoard").scrollTop==20&&clearInterval(scrollID)} function SetBulletin(){var a;document.getElementById("bulletinBoard").innerHTML="";for(a=0;a<maxLines+1;a++){document.getElementById("bulletinBoard").innerHTML+=bulletinContent[(bulletinIndex+a)%bulletinContent.length];if(a<maxLines)document.getElementById("bulletinBoard").innerHTML+="<br/>"}}$(function(){$("#bulletinBoard").mouseover(function(){clearInterval(changeID)})});$(function(){$("#bulletinBoard").mouseout(function(){changeID=setInterval("ChangeBulletin()",changeDelay)})}); function img_show(a){cells=document.getElementsByName(a);for(j=0;j<cells.length;j++)cells[j].style.visibility="visible"}function img_hidden(a){cells=document.getElementsByName(a);for(j=0;j<cells.length;j++)cells[j].style.visibility="hidden"}function copyText(a){var d=document.body.createTextRange();d.moveToElementText(a);d.scrollIntoView();d.select();d.execCommand("Copy");d.collapse(false)} jQuery(document).ready(function(a){a(".post h2 a").click(function(){a(this).text("\u9875\u9762\u8f7d\u5165\u4e2d\u2026\u2026");window.location=a(this).attr("href")});a(".read_more a").click(function(){a(this).text("\u8f7d\u5165\u4e2d\u2026");window.location=a(this).attr("href")})});jQuery(document).ready(function(a){a(".thumb_pic").lazyload({effect:"fadeIn"})});