if(typeof deconcept=="undefined"){var deconcept=new Object()}if(typeof deconcept.util=="undefined"){deconcept.util=new Object()}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object()}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a,_b){if(!document.createElement||!document.getElementById){return }this.DETECT_KEY=_b?_b:"detectflash";this.skipDetect=true;this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1)}if(id){this.setAttribute("id",id)}if(w){this.setAttribute("width",w)}if(h){this.setAttribute("height",h)}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")))}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion(this.getAttribute("version"),_7);if(c){this.addParam("bgcolor",c)}else{}var q=_8?_8:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",_7);this.setAttribute("doExpressInstall",false);var _d=(_9)?_9:window.location;this.setAttribute("xiRedirectUrl",_d);this.setAttribute("redirectUrl","");if(_a){this.setAttribute("redirectUrl",_a)}};deconcept.SWFObject.prototype={setAttribute:function(_e,_f){this.attributes[_e]=_f},getAttribute:function(_10){return this.attributes[_10]},addParam:function(_11,_12){this.params[_11]=_12},getParams:function(){return this.params},addVariable:function(_13,_14){this.variables[_13]=_14},getVariable:function(_15){return this.variables[_15]},getVariables:function(){return this.variables},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16.push(key+"="+_18[key])}return _16},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn")}_19='<embed type="application/x-shockwave-flash" src="'+this.getAttribute("swf")+'" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'"';_19+=' id="'+this.getAttribute("id")+'" name="'+this.getAttribute("id")+'" ';var _1a=this.getParams();for(var key in _1a){_19+=[key]+'="'+_1a[key]+'" '}var _1c=this.getVariablePairs().join("&");if(_1c.length>0){_19+='flashvars="'+_1c+'"'}_19+=' pluginspage="http://www.macromedia.com/go/getflashplayer"/>'}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX")}_19='<object id="'+this.getAttribute("id")+'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0">';_19+='<param name="movie" value="'+this.getAttribute("swf")+'" />';var _1d=this.getParams();for(var key in _1d){_19+='<param name="'+key+'" value="'+_1d[key]+'" />'}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+='<param name="flashvars" value="'+_1f+'" />'}_19+="</object>"}return _19},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title)}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"))}}return false}};deconcept.SWFObjectUtil.getPlayerVersion=function(_23,_24){var _25=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_25=new deconcept.PlayerVersion(x.description.replace(/([a-z]|[A-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."))}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");for(var i=15;i>6;i--){try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+i);_25=new deconcept.PlayerVersion([i,0,0]);break}catch(e){}}}catch(e){}if(_23&&_25.major>_23.major){return _25}if(!_23||((_23.minor!=0||_23.rev!=0)&&_25.major==_23.major)||_25.major!=6||_24){try{_25=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","))}catch(e){}}}return _25};deconcept.PlayerVersion=function(_29){this.major=parseInt(_29[0])!=null?parseInt(_29[0]):0;this.minor=parseInt(_29[1])||0;this.rev=parseInt(_29[2])||0};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.major<fv.major){return false}if(this.major>fv.major){return true}if(this.minor<fv.minor){return false}if(this.minor>fv.minor){return true}if(this.rev<fv.rev){return false}return true};deconcept.util={getRequestParameter:function(_2b){var q=document.location.search||document.location.hash;if(q){var _2d=q.indexOf(_2b+"=");var _2e=(q.indexOf("&",_2d)>-1)?q.indexOf("&",_2d):q.length;if(q.length>1&&_2d>-1){return q.substring(q.indexOf("=",_2d)+1,_2e)}}return""}};if(Array.prototype.push==null){Array.prototype.push=function(_2f){this[this.length]=_2f;return this.length}}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;
var Native=function(){};Native.implement=function(D,C){for(var B=0,A=D.length;B<A;B++){D[B].implement(C)}};Native.genericize=function(B,C,A){if((!A||!B[C])&&typeof B.prototype[C]=="function"){B[C]=function(){var D=Array.prototype.slice.call(arguments);return B.prototype[C].apply(D.shift(),D)}}};(function(D){var G=true,A=true;var C=function(I,J,H){if((!H||!I[J])&&typeof I.prototype[J]=="function"){I[J]=function(){var K=Array.prototype.slice.call(arguments);return I.prototype[J].apply(K.shift(),K)}}};var E=function(J,H,K,I){if(!A||I||!J.prototype[H]){J.prototype[H]=K}if(G){C(J,H,A)}return J};var F=function(I,H,K){if(typeof I=="string"){return E(this,I,H,K)}for(var J in I){E(this,J,I[J],H)}return this};for(var B in D){D[B].implement=F}})({String:String,Function:Function,Number:Number,Array:Array,RegExp:RegExp,Date:Date});(function(B,A){for(var C=A.length;C--;C){Native.genericize(B,A[C],true)}return arguments.callee})(Array,["pop","push","reverse","shift","sort","splice","unshift","concat","join","slice","toString","valueOf","indexOf","lastIndexOf"])(String,["charAt","charCodeAt","concat","indexOf","lastIndexOf","match","replace","search","slice","split","substr","substring","toLowerCase","toUpperCase","valueOf"]);function $(A){return(typeof A=="string")?document.getElementById(A):A}function $defined(A){return(A!=undefined)}function $try(){for(var B=0,A=arguments.length;B<A;B++){try{return arguments[B]()}catch(C){}}return null}function $type(A){if(A==undefined){return false}if(A instanceof Array){return"array"}if(A instanceof Date){return"date"}if(A instanceof RegExp){return"regex"}if(A.nodeName){switch(A.nodeType){case 1:return"element";case 3:return(/\S/).test(A.nodeValue)?"textnode":"whitespace"}}else{if(typeof A.length=="number"){if(A.callee){return"arguments"}else{if(A.item){return"collection"}}}}return typeof A}function $splat(B){var A=$type(B);return(A)?((A!="array"&&A!="arguments")?[B]:B):[]}function $random(B,A){return Math.floor(Math.random()*(A-B+1)+B)}function $clear(A){clearTimeout(A);clearInterval(A);return null}function $extend(C,A){for(var B in (A||{})){C[B]=A[B]}return C}function $unlink(C){var B;switch($type(C)){case"object":B={};for(var E in C){B[E]=$unlink(C[E])}break;case"array":B=[];for(var D=0,A=C.length;D<A;D++){B[D]=$unlink(C[D])}break;default:return C}return B}function $merge(){var E={};for(var D=0,A=arguments.length;D<A;D++){var B=arguments[D];if($type(B)!="object"){continue}for(var C in B){var G=B[C],F=E[C];E[C]=(F&&$type(G)=="object"&&$type(F)=="object")?$merge(F,G):$unlink(G)}}return E}function $A(C){if(C.item){var D=[];for(var B=0,A=C.length;B<A;B++){D[B]=C[B]}return D}return $type(C)=="number"?[C]:Array.apply(C)}function $empty(){}String.implement({substitute:function(A,B){return this.replace(B||(/\\?\{([^}]+)\}/g),function(D,C){if(D.charAt(0)=="\\"){return D.slice(1)}return(A[C]!=undefined)?A[C]:""})}});Array.implement({each:function(C,D){for(var B=0,A=this.length;B<A;B++){C.call(D,this[B],B,this)}},every:function(C,D){for(var B=0,A=this.length;B<A;B++){if(!C.call(D,this[B],B,this)){return false}}return true},filter:function(D,E){var C=[];for(var B=0,A=this.length;B<A;B++){if(D.call(E,this[B],B,this)){C.push(this[B])}}return C},clean:function(){return this.filter($defined)},indexOf:function(C,D){var A=this.length;for(var B=(D<0)?Math.max(0,A+D):D||0;B<A;B++){if(this[B]===C){return B}}return -1},map:function(D,E){var C=[];for(var B=0,A=this.length;B<A;B++){C[B]=D.call(E,this[B],B,this)}return C},some:function(C,D){for(var B=0,A=this.length;B<A;B++){if(C.call(D,this[B],B,this)){return true}}return false},link:function(C){var A={};for(var E=0,B=this.length;E<B;E++){for(var D in C){if(C[D](this[E])){A[D]=this[E];delete C[D];break}}}return A},contains:function(A,B){return this.indexOf(A,B)!=-1},extend:function(C){for(var B=0,A=C.length;B<A;B++){this.push(C[B])}return this},include:function(A){if(!this.contains(A)){this.push(A)}return this},erase:function(B){for(var A=this.length;A--;A){if(this[A]===B){this.splice(A,1)}}return this},flatten:function(){var D=[];for(var B=0,A=this.length;B<A;B++){var C=$type(this[B]);if(!C){continue}D=D.concat((C=="array"||C=="collection"||C=="arguments")?Array.flatten(this[B]):this[B])}return D}});Function.implement({create:function(B){var A=this;B=B||{};return function(D){var C=B.arguments;C=(C!=undefined)?$splat(C):Array.slice(arguments,(B.event)?1:0);if(B.event){C=[D||window.event].extend(C)}var E=function(){return A.apply(B.bind||null,C)};if(B.delay){return setTimeout(E,B.delay)}if(B.periodical){return setInterval(E,B.periodical)}return E()}},bind:function(B,A){return this.create({bind:B,arguments:A})},bindWithEvent:function(B,A){return this.create({bind:B,event:true,arguments:A})},delay:function(B,C,A){return this.create({delay:B,bind:C,arguments:A})()},periodical:function(A,C,B){return this.create({periodical:A,bind:C,arguments:B})()}});function using(B){B=B.split(/\s*\.\s*/g);var A=window,C;B.each(function(D){if(C){C+="."+D}else{C=D}if(!A[D]){A[D]={$name:C}}else{if(!A[D].$name){A[D].$name=C}}A=A[D]});return A}function include(B,C,A){A=Array.slice(arguments,2).flatten()||[];A.each(function(D){document.write('<script type="text/javascript" charset="'+C+'" src="'+B+D+'"><\/script>')})}function require(D,E,C){C=Array.slice(arguments,2).flatten()||[];var A=Array.filter(document.getElementsByTagName("script"),function(F){return F.getAttribute("src")}).map(function(F){return F.getAttribute("src")});C=C.filter(function(F,G){return !A.contains(D+F)});var B=document.getElementsByTagName("head")[0];C.each(function(F){(function(){var G=document.createElement("script");G.charset=E||"GBK";G.src=D+F;B.appendChild(G);G=null}).delay(10)})}(function(A){A.Engine={name:"unknown",version:""};A.Platform={name:(navigator.platform.match(/mac|win|linux/i)||["other"])[0].toLowerCase()};A.Features={xpath:!!(document.evaluate),air:!!(window.runtime)};A.Plugins={};if(window.opera){A.Engine={name:"presto",version:(document.getElementsByClassName)?950:925}}else{if(window.ActiveXObject){A.Engine={name:"trident",version:(window.XMLHttpRequest)?5:4}}else{if(!navigator.taintEnabled){A.Engine={name:"webkit",version:(A.Features.xpath)?420:419}}else{if(document.getBoxObjectFor!=null){A.Engine={name:"gecko",version:(document.getElementsByClassName)?19:18}}}}}A.Engine[A.Engine.name]=A.Engine[A.Engine.name+A.Engine.version]=true;if(window.orientation!=undefined){A.Platform.name="ipod"}A.Platform[A.Platform.name]=true;A.Request=function(){return $try(function(){return new XMLHttpRequest()},function(){return new ActiveXObject("MSXML2.XMLHTTP")})};A.Features.xhr=!!(A.Request());A.Features.range=document.implementation.hasFeature("Range","2.0");A.Plugins.Flash=(function(){var B=($try(function(){return navigator.plugins["Shockwave Flash"].description},function(){return new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version")})||"0 r0").match(/\d+/g);return{version:parseInt(B[0]||0+"."+B[1]||0),build:parseInt(B[2]||0)}})()})(using("ccydt.Browser"));(function(B){var C=function(){ccydt.Browser.loaded=true};var A=(function(){var D=document;return ccydt.Browser.Engine.trident?function(F){if(ccydt.Browser.loaded){F()}else{var E=D.createElement("div");(function(){try{E.doScroll("left");D.body.appendChild(E);E.innerHTML="temp";D.body.removeChild(E);C();F()}catch(G){setTimeout(arguments.callee,50)}})()}}:ccydt.Browser.webkit?function(E){(function(){if(/loaded|complete/.test(D.readyState)){C();E()}else{setTimeout(arguments.callee,10)}})()}:function(E){if(ccydt.Browser.loaded){E()}else{D.addEventListener("DOMContentLoaded",C,false);D.addEventListener("DOMContentLoaded",E,false)}}})();B.add=function(G,F,E,H,D){if(G===window&&F.toLowerCase()=="domready"){A(E);return this}if(G.addEventListener){G.addEventListener(F,E,false)}else{G.attachEvent("on"+F,E)}return this};B.remove=function(F,E,D){if(F.removeEventListener){F.removeEventListener(E,D,false)}else{F.detachEvent("on"+E,D)}return this};B.stop=function(D){return this.stopPropagation(D).preventDefault(D)};B.stopPropagation=function(D){if(D.stopPropagation){D.stopPropagation()}else{D.cancelBubble=true}return this};B.preventDefault=function(D){if(D.preventDefault){D.preventDefault()}else{D.returnValue=false}return this};window.addEvent=function(E,D){B.add(window,E,D)};window.removeEvent=function(E,D){B.remove(window,E,D)}})(using("ccydt.Event"));(function(A){A.Events={addEvent:function(D,C,B){D=this.removeOn(D);if(!this.$events){this.$events={}}if(C!=$empty){this.$events[D]=this.$events[D]||[];this.$events[D].include(C);if(B){C.internal=true}}return this},addEvents:function(B){for(var C in B){this.addEvent(C,B[C])}return this},fireEvent:function(D,C,B){D=this.removeOn(D);if(!this.$events||!this.$events[D]){return this}this.$events[D].each(function(E){E.create({bind:this,delay:B,"arguments":C})()},this);return this},removeEvent:function(C,B){C=this.removeOn(C);if(!this.$events[C]){return this}if(!B.internal){this.$events[C].erase(B)}return this},removeEvents:function(D){if($type(D)=="object"){for(var E in D){this.removeEvent(E,D[E])}return this}if(D){D=this.removeOn(D)}for(var E in this.$events){if(D&&D!=E){continue}var C=this.$events[E];for(var B=C.length;B--;B){this.removeEvent(E,C[B])}}return this},removeOn:function(B){return B.replace(/^on([A-Z])/,function(C,D){return D.toLowerCase()})}}})(using("ccydt"));(function(A){A.hideOutline=function(B){if(ccydt.Browser.Engine.trident){B.hideFocus=true}else{B.style.outline="none"}};A.isAscii=function(B){if(B>0&&B<=255){return true}return false};A.getLength=function(D){if(typeof (D)!="string"&&typeof (D)!="number"){return 0}D=""+D;var B=0;for(var C=0,E=D.length;C<E;C++){B+=A.isAscii(D.charCodeAt(C))?1:2}return B};A.cutString=function(G,F,D){var C=0,B=0;if(F>=A.getLength(G)){return G}var E="";while(C<F){E+=G.charAt(B);C+=A.isAscii(G.charCodeAt(B))?1:2;B+=1}if(C>F){E=E.substr(0,E.length-1)}if(D&&D!=""){E+=D}return E}})(using("ccydt.Utils"));(function(A){A.write=function(D,E,C){E=encodeURIComponent(E);C=$extend({path:false,domain:false,duration:false,secure:false,document:document},C);if(C.domain){E+="; domain="+C.domain}if(C.path){E+="; path="+C.path}if(C.duration){var B=new Date();B.setTime(B.getTime()+C.duration*24*60*60*1000);E+="; expires="+B.toGMTString()}if(C.secure){E+="; secure"}C.document.cookie=D+"="+E};A.read=function(C,B){B=$extend({path:false,domain:false,duration:false,secure:false,document:document},B);var D=B.document.cookie.match("(?:^|;)\\s*"+C.replace(/([-.*+?^${}()|[\]\/\\])/g,"\\$1")+"=([^;]*)");return(D)?decodeURIComponent(D[1]):null};A.dispose=function(C,B){this.write(C,"",$extend($extend({},B),{duration:-1}))}})(using("ccydt.Cookie"));(function(B){var C={img:"http://img.ccydt.com",podcast:"http://v.ccydt.com",www:"http://www.ccydt.com",blog:"http://blog.ccydt.com",passport:"http://passport.ccydt.com",space:"http://zone.ccydt.com"};for(var A in C){B[A]=C[A];B["_"+A]=C[A].replace(/^http(s?):\/\//i,"")}B.domain=".ccydt.com"})(using("ccydt.Urls"));(function(A){A.doLogin=ccydt.Urls.passport+"/login_doLogin.htm";A.doLogout=ccydt.Urls.passport+"/login_doLogout.htm";A.doRegister=ccydt.Urls.passport+"/register_doRegister.htm"})(using("ccydt.Library.Action"));(function(A){A.getPodcastUrl=function(D,B){var C=ccydt.Urls.podcast+"/";if(B){return C+B.replace(/^\//g,"")}if(!isNaN(D)&&parseInt(D,10)>9999){return C+"u/"+D}return null};A.getSpaceUrl=function(C,B){if(B){return"http://"+B+"."+ccydt.Urls._space}if(!isNaN(C)&&parseInt(C,10)>9999){return ccydt.Urls.space+"/u/"+C}return null}})(using("ccydt.Utils"));
(function($ns){$ns.switchTab=function(a,n,i,pre,cls){cls=cls||"current";if(a){this.hideOutline(a)}for(var j=0;j<n;j++){if($(pre+"_t"+j)){$(pre+"_t"+j).className=(j==i?cls:"")}var src=ccydt.Urls.www+"/"+pre+"/"+j+"/index.html";if(j==i&&$(pre+"_i"+j)&&$(pre+"_i"+j).src!=src){$(pre+"_i"+j).src=src}if($(pre+"_c"+j)){$(pre+"_c"+j).style.display=(j==i?"":"none")}}};$ns.defaultKey="\u8bf7\u8f93\u5165\u67e5\u8be2\u5185\u5bb9";$ns.doFocus=function(o){if(o.value==this.defaultKey){o.value="";o.style.color="black"}};$ns.doBlur=function(o){if(o.value==""||o.value==this.defaultKey){o.value=this.defaultKey;o.style.color="#bbb"}else{o.style.color="black"}};$ns.setSearch=function(n){var inputs=document.getElementsByName(n);this.doBlur(inputs[0]);this.doBlur(inputs[1])};$ns.doSearch=function(frm){var v=frm.inp.value.replace(/[&\?\/]/g," ");if(v==""||v=="\u8bf7\u8f93\u5165\u67e5\u8be2\u5185\u5bb9"){alert("\u8bf7\u8f93\u5165\u67e5\u8be2\u5185\u5bb9 ^_^ ");frm.inp.focus();return false}else{var inp=encodeURIComponent(v);var type=frm.searchType.value;var url={movie:"http://m.ccydt.com/search.html?stype=2&keyword="+v,yahoo:"http://search.union.yahoo.com.cn/click/search.htm?m=419561&b=&p=1006&a=&st=0&fw=union&name="+v,zk:"http://z.ccydt.com/search.htm?t=question&q="+v}[type];if(!url){url="p/s.php?l="+{hospital:"h",doctor:"d",jibian:"j",baoji:"b",yangbian:"y",shuji:"s",zy:"z"}[type]+"&q="+inp}window.open(url);return false}};$ns.showSelOption=function(e){with($("selOption").style){display={none:"block",block:"none"}[display]}if(e){ccydt.Event.preventDefault(e)}return false};$ns.changeType=function(searchType,href){$("searchType").value=searchType;$("selOption").style.display="none";$("typeSelected").innerHTML=href.innerHTML;$("inp").focus();$clear(this.timer);return false};$ns.drop_mouseover=function(){$clear(this.timer)};$ns.drop_mouseout=function(){if($("selOption").style.display!="none"){this.timer=this.drop_hide.delay(1000)}};$ns.drop_hide=function(){$("selOption").style.display="none"};$ns.getPosition=function(el){var el=$(el),x=0,y=0;do{x+=el.offsetLeft||0;y+=el.offsetTop||0;el=el.offsetParent}while(el);return{x:x,y:y}};$ns.addFavorite=function(){if(document.all&&!window.opera){window.external.addFavorite(ccydt.Urls.www,"\u91776\u7f51")}else{if(window.sidebar){window.sidebar.addPanel("\u91776\u7f51",ccydt.Urls.www,"")}else{alert("\u8bf7\u4f7f\u7528Ctrl+D\u5c06\u672c\u9875\u52a0\u5165\u6536\u85cf\u5939")}}return false};$ns.setHome=function(obj,vrl){try{obj.style.behavior="url(#default#homepage)";obj.setHomePage(vrl)}catch(e){if(window.netscape){try{netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect")}catch(e){alert("\u62b1\u6b49\uff01\u60a8\u7684\u6d4f\u89c8\u5668\u4e0d\u652f\u6301\u76f4\u63a5\u8bbe\u4e3a\u9996\u9875\u3002\r\n\u8bf7\u5728\u6d4f\u89c8\u5668\u5730\u5740\u680f\u8f93\u5165\u201cabout:config\u201d\u5e76\u56de\u8f66\u7136\u540e\u5c06[signed.applets.codebase_principal_support]\u8bbe\u7f6e\u4e3a\u201ctrue\u201d\uff0c\u70b9\u51fb\u201c\u52a0\u5165\u6536\u85cf\u201d\u540e\u5ffd\u7565\u5b89\u5168\u63d0\u793a\uff0c\u5373\u53ef\u8bbe\u7f6e\u6210\u529f\u3002")}try{var prefs=Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefBranch);prefs.setCharPref("browser.startup.homepage",vrl)}catch(e){}}}}})(using("ccydt.Utils"));(function(H){var C=ccydt.Urls,B=ccydt.Library.Action,N=ccydt.Event;$extend(H,$unlink(ccydt.Events));H.overTime=30*1000;H.referKey="www";var K={name:"account",pass:"password",expire:"expire"};var O=["\u9a8c\u8bc1\u5904\u7406\u4e2d,\u8bf7\u7a0d\u7b49...","\u7528\u6237\u540d\u4e0d\u80fd\u4e3a\u7a7a","\u7528\u6237\u540d\u4e0d\u80fd\u542b\u6709\u4e2d\u6587\u5b57\u7b26(\u8001\u7528\u6237\u9664\u5916)","\u7528\u6237\u540d\u957f\u5ea64-16\u4f4d(1\u4e2d\u6587\u53602\u4f4d)","\u5bc6\u7801\u4e0d\u80fd\u4e3a\u7a7a","\u5bc6\u7801\u4e0d\u80fd\u542b\u6709\u4e2d\u6587\u5b57\u7b26","\u5bc6\u7801\u957f\u5ea64-16\u4f4d","\u7528\u6237\u540d\u4e0d\u5b58\u5728","\u5bc6\u7801\u9519\u8bef","\u53d1\u751f\u672a\u77e5\u9519\u8bef,\u8bf7\u91cd\u8bd5!"];var E=C.img+"/common/defcover/{gender}_{size}.gif";function D(P){return["boy","girl","both"][P]||"both"}function M(R,Q){var P=(R||"").split(";");return{big:P[0]||E.substitute({gender:D(Q),size:"big"}),small:P[1]||P[0]||E.substitute({gender:D(Q),size:"small"}),middle:P[2]||P[1]||P[0]||E.substitute({gender:D(Q),size:"small"})}}function J(){var T=ccydt.Cookie.read("systemPPCLoginUser");if(!T){return null}var S=T.split("_--_");if(S.length!=5||isNaN(S[0])||parseInt(S[0])<=999){return null}var Q=ccydt.Cookie.read("systemPPCLoginUserNickName"),P=ccydt.Cookie.read("systemPPCLoginUserHeadFace"),R=M(P);return{uid:S[0],url:S[1],username:S[2],email:S[3],service:S[4],nick:Q?unescape(Q.replace(/\\/ig,"%")):null,icon:P,bigIcon:R.big,middleIcon:R.middle,smallIcon:R.small}}function L(){if(H.form){var P=H.form.elements;if(P[K.name]){P[K.name].value=""}if(P[K.pass]){P[K.pass].value=""}if(P[K.expire]){P[K.expire].defaultChecked=true;P[K.expire].setAttribute("checked","checked")}}}function A(P){if(H.form){var Q=H.form.elements;if(Q[P]){Q[P].focus()}}}function G(P){alert(O[P])}function F(P,Q){if(P==""){G(1);A(K.name);return false}if(Q==""){G(4);A(K.pass);return false}if(Q.length<4||Q.length>16){G(6);A(K.pass);return false}if((/[^\x00-\xff]/).test(Q)){G(5);A(K.pass);return false}return true}function I(P){var Q=document.createElement("script");Q.src=P;Q.type="text/javascript";(function(){document.getElementsByTagName("head")[0].appendChild(Q)}).delay(10);return Q}H.login=function(V,R){if(V){N.preventDefault(V)}if(this.logining){alert("正在登录请稍后...")}else{if(!this.form&&R){this.form=R}if(this.form){var W=this.getRefer(),U=H.form.elements,Q=U[K.name]?U[K.name].value:"",X=U[K.pass]?U[K.pass].value:"",S=U[K.expire]?U[K.expire].checked:false;if(F(Q,X)){var T="loginName="+Q;T+="&password="+encodeURIComponent(X);T+="&callBackMethod="+this.$name+".onLogin";if(S){T+="&expire="+1209600}if(W&&W!=""){T+="&refer="+W}var P=B.doLogin;P+=(P.indexOf("?")<0?"?":"&")+T+"&"+(new Date()).getTime();this.logining=true;this.loginTimer=function(){$clear(H.loginTimer);delete H.loginTimer;if(H.logining){H.logining=false;alert("登录超时,请刷新页面重试!")}}.delay(this.getOverTime());I(P)}}}};H.logout=function(S){if(S){N.preventDefault(S)}if(this.logouting){alert("正在退出请稍后...")}else{var R=this.getRefer();var Q="redirect=0&callBackMethod="+this.$name+".onLogout";if(R&&R!=""){Q+="&refer="+R}var P=B.doLogout;P+=(P.indexOf("?")<0?"?":"&")+Q+"&"+(new Date()).getTime();this.logouting=true;this.logoutTimer=function(){$clear(H.logoutTimer);delete H.logoutTimer;if(H.logouting){H.logouting=false;alert("退出超时,请刷新页面重试!")}}.delay(this.getOverTime());I(P)}};H.onLogin=function(P,Q){this.logining=false;$clear(this.loginTimer);delete this.loginTimer;if(P&&(parseInt(P.status)==227||parseInt(P.status)==229)){this.update();L();var R=this.getRedirect();if(R){window.location.href=R}this.fireEvent("login")}else{alert(P?P.msgText:"\u670d\u52a1\u5668\u5fd9");this.fireEvent("error",["login",P])}};H.onLogout=function(P,Q){this.logouting=false;$clear(H.logoutTimer);delete H.logoutTimer;this.update();var R=this.getRedirect();if(R!=null&&R!=""){window.location.href=R}this.fireEvent("logout")};H.update=function(){if(this.panel){var Q=J();if(Q){var R=[],P=!!Q.url,S=P?ccydt.Utils.getSpaceUrl(Q.uid,Q.url):C.space+"/user.htm?t=active&from="+encodeURIComponent(window.location.href);R.push('<div class="log_fl">');R.push('<a href="'+S+(P?"/home/":"")+'" target="_blank"><img src="'+Q.smallIcon+'" title="'+Q.nick+'" alt="'+Q.nick+'" class="icon_small" /></a>');R.push('<p><a target="_blank" href="'+S+(P?"/profile/":"")+'" class="af00 fr">编辑资料</a></p>');R.push("</div>");R.push('<div class="log_fr">');R.push('<p class="cfix"><a href="#" onclick="'+this.$name+'.logout(event)" class="fr tuichu">退出</a><strong class="log_name">hi,'+Q.nick+"</strong></p>");R.push('<p class="border">');if(P){R.push('<a class="a2" target="_blank" href="'+S+'/addentry.html">写新文章</a>&nbsp;&nbsp;|&nbsp;&nbsp;')}R.push('<a class="a4" target="_blank" href="'+C.podcast+'/upload.htm">上传视频</a></p>');R.push('<a href="'+S+(P?"/home/":"")+'" target="_blank" class="'+(P?"btn_jrkj":"btn_jhkj")+'"></a>');R.push("</div>");this.panel.innerHTML=R.join("");delete this.form}else{this.panel.innerHTML=this.cache||"";delete this.form}}return this};H.setRedirect=function(P){this.redirectUrl=P;return this};H.getRedirect=function(){return this.redirectUrl};H.setRefer=function(P){this.referKey=P;return this};H.getRefer=function(){return this.referKey};H.setOverTime=function(P){this.overTime=P;return this};H.getOverTime=function(P){return this.overTime};H.init=function(P){this.panel=$(P);if(this.panel){this.cache=this.panel.innerHTML}this.update();delete this.init}})(using("ccydt.Logon"));
(function(A){A.AutoCompleteTip=function(){this.initialize.apply(this,arguments)};A.AutoCompleteTip.UID=1;A.AutoCompleteTip.prototype={initialize:function(B){B=B||{};if(!B.name||window[B.name]){return window[B.name]}this.name=B.name;this.uid=A.AutoCompleteTip.UID++;this.options={minWidth:B.minWidth||280,size:B.size||10,fetchDelay:B.fetchDelay||500,autoHide:B.autoHide||false,hideDelay:B.hideDelay||0,action:B.action||null,input:B.input||null,onclick:B.onclick||null,boxCls:B.boxCls||"acBox",resultsCls:B.resultsCls||"acRs",resultCls:B.resultCls||"acR",resultFocusCls:B.resultFocusCls||"focus",keyCls:B.keyCls||"acRK",statCls:B.statCls||"acRC",closeCls:B.closeCls||"acC",prefix:B.prefix||"_ac_",statSuffix:B.statSuffix||" videos",closeLang:B.closeLang||" close"};delete B;B=null;this.bound={};this.resultPrefix=this.options.prefix+this.uid+"r";if(this.options.input){this.inputEl=document.getElementById(this.options.input)}this.bindEvents();return this},build:function(){if(!this.builded){ccydt.Event.add(window,"unload",this.destory.bind(this));this.el=document.createElement("div");document.body.appendChild(this.el);this.el.style.display="none";this.el.className=this.options.boxCls;this.el.style.width=Math.max(this.inputEl.offsetWidth,this.options.minWidth)+"px";this.el.innerHTML='<ul class="'+this.options.resultsCls+'"></ul>';this.bound.elMouseOver=function(){if(this.inputEl){this.inputEl.focus()}if(this.autoHideTimer!=null){$clear(this.autoHideTimer)}}.bind(this);ccydt.Event.add(this.el,"mouseover",this.bound.elMouseOver);this.resultsEl=this.el.getElementsByTagName("ul")[0];if(this.resultsEl){this.bound.resultsMouseOver=function(D){D=D||event;var C=D.srcElement||D.target;var B=C.tagName.toLowerCase();if(B=="ul"){return }if(B!="li"){C=C.parentNode}this.changeFocus(C)}.bind(this);ccydt.Event.add(this.resultsEl,"mouseover",this.bound.resultsMouseOver);this.bound.resultsMouseDown=function(D){D=D||event;if(D.stopPropagation){D.stopPropagation()}else{D.cancelBubble=true}if(D.preventDefault){D.preventDefault()}else{D.returnValue=false}var C=D.srcElement||D.target;var B=C.tagName.toLowerCase();if(B=="ul"){return }if(B=="span"&&C.className==this.options.closeCls){this.hide();return }if(B!="li"){C=C.parentNode}if(C.className.indexOf(this.options.resultCls)>=0){this.changeFocus(C).fillKey(C.getElementsByTagName("span")[1].innerHTML).hide();if(typeof this.options.onclick=="function"){this.options.onclick()}}}.bind(this);ccydt.Event.add(this.resultsEl,"mousedown",this.bound.resultsMouseDown)}this.builded=true}return this},destory:function(){$clear(this.fetchDelayHD);$clear(this.autoHideTimer);if(this.inputEl){ccydt.Event.remove(this.inputEl,"keyup",this.bound.inputKeyUp);ccydt.Event.remove(this.inputEl,"blur",this.bound.inputBlur);delete this.bound.inputKeyUp;delete this.bound.inputBlur;this.inputEl=null}if(this.fetchEl){this.fetchEl.parentNode.removeChild(this.fetchEl);this.fetchEl=null}if(this.resultsEl){ccydt.Event.remove(this.resultsEl,"mouseover",this.bound.resultsMouseOver);ccydt.Event.remove(this.resultsEl,"mousedown",this.bound.resultsMouseDown);delete this.bound.resultsMouseOver;delete this.bound.resultsMouseDown;this.resultsEl=null}if(this.el){ccydt.Event.remove(this.el,"mouseover",this.bound.elMouseOver);delete this.bound.elMouseOver;this.el.parentNode.removeChild(this.el);this.el=null}},bindEvents:function(){if(this.inputEl){this.inputEl.setAttribute("autocomplete","off");this.bound.inputKeyUp=function(D){D=D||event;var C=D.keyCode;if(C==38){this.scrollUp()}else{if(C==40){this.scrollDown()}else{if(this.inputEl.value==""){this.hide()}else{if(this.inputEl.value==this.lastSearch){this.show()}else{$clear(this.fetchDelayHD);var B=this.inputEl.value;this.fetchDelayHD=(function(){this.fetch(B)}).delay(this.options.fetchDelay,this)}}}}}.bind(this);ccydt.Event.add(this.inputEl,"keyup",this.bound.inputKeyUp);if(this.options.autoHide){this.bound.inputBlur=function(){if(this.options.autoHide){if(this.options.hideDelay){this.autoHideTimer=(function(){this.hide()}).delay(this.options.hideDelay,this)}else{this.hide()}}}.bind(this);ccydt.Event.add(this.inputEl,"blur",this.bound.inputBlur)}}return this},show:function(){if(!this.builded){this.build()}$clear(this.autoHideTimer);if(!this.showing){this.showing=true;if(this.inputEl){var B=ccydt.Utils.getPosition(this.inputEl);this.moveTo({left:B.x,top:B.y+this.inputEl.offsetHeight})}if(this.el){this.el.style.display=""}}return this},hide:function(){if(this.showing){this.showing=false;if(this.el){this.el.style.display="none"}}return this},moveTo:function(B){if(this.el&&B){if(B.left){this.el.style.left=B.left+"px"}if(B.top){this.el.style.top=B.top+"px"}}return this},scrollUp:function(){return this.scroll(true)},scrollDown:function(){return this.scroll(false)},changeFocus:function(B){if(B&&B.className==this.options.resultCls){var C=this.resultPrefix;var D=document.getElementById(C+this.focusIndex);if(D){D.className=this.options.resultCls}B.className=this.options.resultCls+" "+this.options.resultFocusCls;this.focusIndex=parseInt(B.id.replace(C,""))}return this},scroll:function(D){if(!this.builded){this.build()}if(this.resultsEl){var B=this.resultsEl.getElementsByTagName("li");if(B.length>0){this.show();if(this.focusIndex>=0){B[this.focusIndex].className=this.options.resultCls}if(D){var C=this.focusIndex>=0?(this.focusIndex-1):(B.length-2)}else{var C=(this.focusIndex+2)>=B.length?-1:(this.focusIndex+1)}if(C>=0){B[C].className=this.options.resultCls+" "+this.options.resultFocusCls}this.focusIndex=C;this.fillKey(C>=0?B[C].getElementsByTagName("span")[1].innerHTML:this.lastSearch)}B=null}return this},fillKey:function(B){if(this.inputEl){this.inputEl.focus();this.inputEl.value=B;this.inputEl.select()}return this},fetch:function(){if(!this.inputEl||!this.inputEl.value||this.inputEl.value==this.lastSearch){return }var B=this.inputEl.value;if(this.fetchEl){this.fetchEl.parentNode.removeChild(this.fetchEl);this.fetchEl=null}this.fetchEl=document.createElement("script");this.fetchEl.setAttribute("language","javascript");this.fetchEl.setAttribute("type","text/javascript");document.getElementsByTagName("head")[0].appendChild(this.fetchEl);this.lastTime=(new Date()).getTime();var C=this.options.action;if(C){C+=C.indexOf("?")>=0?"&":"?";C+="key="+encodeURIComponent(B)+"&n="+this.name+".response&cp="+this.lastTime;this.fetchEl.src=C;this.onFetch(B)}},onFetch:function(B){this.lastSearch=B},response:function(B,C){if(typeof B=="object"&&this.lastTime==C&&(this.inputEl.value!="")){this.render(B)}},onEmpty:function(){this.hide().cleanResult()},cleanResult:function(){this.focusIndex=-1;if(this.resultsEl){this.resultsEl.innerHTML=""}},render:function(D){if(!this.builded){this.build()}if(!D||D.length==0){this.onEmpty()}else{if(this.resultsEl){var C=[];var E=this.options;for(var B=0,F=D.length;B<F;B++){C.push('<li id="'+this.resultPrefix+B+'" class="'+E.resultCls+'">');C.push('<span class="'+E.statCls+'">'+D[B].c+E.statSuffix+"</span>");C.push('<span class="'+E.keyCls+'">'+D[B].k+"</span>");C.push("</li>")}C.push('<li style="padding:0 3px;"><span class="'+E.closeCls+'">'+E.closeLang+"</span><span>&nbsp;</span></li>");this.resultsEl.innerHTML=C.join("");C=null;E=null;this.focusIndex=-1;this.show()}}}}})(using("ccydt.Plugin"));
var QuickList={max:30,url:"http://v.ccydt.com/video.htm?t=getVideosByIds&cb=QuickList.build&ids=",key:"QuickList",addClass:"plus",playClass:"arrow",counter:"qlCounter",list:"listContainer",syncWait:500,loadDelay:3000,init:function(){var B=document.links,E;this.retrieve();var D=","+this.value.join(",")+",";for(var C=0,A=B.length;C<A;C++){E=B[C];if(E.className==this.addClass&&E.hash.length>1){E.className=(D.indexOf(","+E.hash.substr(1)+",")>-1)?this.playClass:this.addClass}}this.count()},count:function(){var A=this.value.length;var B=$(this.counter);if(B){B.innerHTML=A?("("+A+")"):"";B.style.display=A?"":"none"}},observe:function(){var A=this.value.join("");this.retrieve();if(A!=this.value.join("")){this.init();$clear(this.updater);this.updater=this.fetch.delay(this.loadDelay,this)}},toggle:function(B){var C=B.target||B.srcElement;ccydt.Event.preventDefault(B);if(C.hash.length>1){var A=C.hash.substr(1);if(this.contains(A)){this.play(A)}else{C.className=this.playClass;this.add(A,true)}}},del:function(C,B){ccydt.Event.preventDefault(C);this.remove(B);var A=(C.target||C.srcElement).parentNode;A.parentNode.removeChild(A)},delAll:function(A){ccydt.Event.preventDefault(A);this.clear();$(this.list).innerHTML=""},clear:function(){this.value=[];this.store("",-1)},contains:function(A,B){this.retrieve(B);return this.value.contains(A)},add:function(A,B){this.retrieve(B);if(this.value.length<this.max){if(!this.contains(A)){this.value.push(A);this.store(this.value.join(","))}}else{alert("抱歉，点播单添加失败：\t\t\n您的当前点播单中的视频数目已经达到上限("+this.max+")\n您可以移除某些视频后再添加。")}},remove:function(A,B){this.retrieve(B);if(this.contains(A)){this.value.erase(A);this.store(this.value.join(","))}},store:function(A,B){ccydt.Cookie.write(this.key,A,{duration:(B||366),domain:"ccydt.com",path:"/"});this.count()},retrieve:function(A){if(!A||!this.value){this.value=ccydt.Cookie.read(this.key);this.value=(this.value?this.value.split(","):[])}return this.value},removend:function(){return true},render:function(){this.init();this.fetch();this.observer=this.observe.periodical(this.syncWait,this)},build:function(E){this.data=E;if(E.status==1){var D=[],B=[];for(var C=0;C<E.data.count;C++){var A=E.data.list[C];if(A){D.push('<li><a href="#" title="删除" class="del" onclick="QuickList.del(event, \''+A.vid+'\')"></a><span><a href="'+ccydt.Urls.podcast+"/show/"+A.vid+'.html#qlist"><img src="http://'+A.picPath.replace("http://","")+'" /></a></span><a href="'+ccydt.Urls.podcast+"/show/"+A.vid+'.html#qlist">'+A.title+"</a></li>")}else{D.push('<li><a href="#" title="删除" class="del" onclick="QuickList.del(event, \''+this.value[C]+'\')"></a><span><a href="#"><img src="http://img.ccydt.com/common/defcover/default_mv.gif" /></a></span>视频不存在或已删除</li>')}}$(this.list).innerHTML=D.join("")}if(this.script&&this.script.parentNode){this.script.parentNode.removeChild(this.script);delete this.script}},fetch:function(){if(!this.value.length){return }var B=document.createElement("script");B.type="text/javascript";B.src=this.url+this.value.join(",")+"&rnd="+Math.random();var A=document.getElementsByTagName("head")[0];A.appendChild(B);this.script=B},save:function(){},playAll:function(A){ccydt.Event.preventDefault(A);this.retrieve();if(this.value[0]){this.play(0)}},play:function(A){window.top.location.href=ccydt.Urls.podcast+"/show/"+($type(A)=="string"?A:this.value[A])+".html#qlist"}};
(function($ns){var ccydt_EVENT=ccydt.Event,BROWSER_ENGINE=ccydt.Browser.Engine,BROWSER_IE=BROWSER_ENGINE.trident;window.getCompatElement=function(){return(!document.compatMode||document.compatMode=="CSS1Compat")?document.getElementsByTagName("html")[0]:document.body};window.getSize=function(){var win=window;if(BROWSER_ENGINE.presto||BROWSER_ENGINE.webkit){return{x:win.innerWidth,y:win.innerHeight}}var doc=this.getCompatElement();return{x:doc.clientWidth,y:doc.clientHeight}};window.getScroll=function(){var win=window;var doc=this.getCompatElement();return{x:win.pageXOffset||doc.scrollLeft,y:win.pageYOffset||doc.scrollTop}};$ns.FloatWindow=function(options){this.options={zIndex:500,duration:400};this.initialize.call(this,options)};$ns.FloatWindow.prototype={initialize:function(options){this.bound={};$extend(this.options,options);this.build()},build:function(){if(this.el){return }var ops=this.options;var type=$type(ops.content);if(type=="element"){this.el=$unlink(ops.content)}else{if(type=="string"){this.el=document.createElement("div");this.el.innerHTML=ops.url?'<iframe width="'+ops.width+'" height="'+ops.height+'" src="'+ops.url+'" scrolling="no" frameborder="0" marginheight="0" marginwidth="0" hspace="0"></iframe>':ops.content;with(this.el.style){position=BROWSER_IE?"absolute":"fixed";bottom=ops.bottom||0;right=ops.right||0;zIndex=ops.zIndex}if(ops.width>=0){this.el.style.width=ops.width+"px"}if(ops.height>=0){this.el.style.height=ops.height+"px"}document.body.appendChild(this.el)}}if(BROWSER_IE){this.attach()}},destory:function(){if(BROWSER_IE){ccydt_EVENT.remove(window,"scroll",this.bound.move)}},attach:function(){var _this=this;this.bound.move=this.onScroll.bindWithEvent(this);ccydt_EVENT.add(window,"scroll",this.bound.move);ccydt_EVENT.add(window,"beforeunload",function(){ccydt_EVENT.remove(window,"beforeunload",arguments.callee);_this.destory()})},onScroll:function(e){if(this.el&&!this.hided){this.el.style.top=window.getSize().y+window.getScroll().y-this.options.height+"px"}},close:function(){this.hided=true;if(this.el){this.el.style.display="none"}if($type(this.options.onClose)=="function"){this.options.onClose()}}}})(using("ccydt.UI"));