var isIE=window.document.all;function $(){var elements=new Array();for(var u=0;u<arguments.length;u++){var element=arguments[u];if(typeof element=='string')element=document.getElementById(element);if(arguments.length==1)return element;elements.push(element);};return elements;};function fShow(cq){$(cq).style.display="block";};function fHidden(cq){$(cq).style.display="none";};function fImage(g,di,cp){if(di==0){var width=g.width;}else{var width=di;};if(cp==0){var height=g.height;}else{var height=cp;};var ey=(g.clientHeight-0)/(g.clientWidth-0),fd=width*ey,ex=height/ey;if(ex>width){g.width=width;g.height=Math.round(fd);};if(fd>height){g.width=Math.round(ex);g.height=height;};};if(!isIE){Document.prototype.loadXML=function(strXML,callback){var objDOMParser=new DOMParser(),objDoc=objDOMParser.parseFromString(strXML,"text/xml");while(this.hasChildNodes()){this.removeChild(this.lastChild);};for(var u=0;u<objDoc.childNodes.length;u++){var objImportedNode=this.importNode(objDoc.childNodes[u],true);this.appendChild(objImportedNode);};if(callback){callback(this);};};};String.prototype.len=eo;String.prototype.htmlencode=cl;String.prototype.htmldecode=cm;String.prototype.changecode=ck;function eo(){var len=0;for(var u=0;u<this.length;u++){if(this.charCodeAt(u)>255){len+=2;}else{len++;};};return len;};function cm(){var j=this;j=j.replace(/&amp;/gi,"&");j=j.replace(/&lt;/gi,"<");j=j.replace(/&gt;/gi,">");j=j.replace(/&quot;/gi,"\"");j=j.replace("<br/>","\n");return j;};function cl(){var j=this;j=j.replace(/&/gi,"&amp;");j=j.replace(/</gi,"&lt;");j=j.replace(/>/gi,"&gt;");j=j.replace(/\"/gi,"&quot;");j=j.replace("\n","<br/>");return j;};function ck(){var result=this;return result;};var path="images/",btn=new Array(),img=new Array(),onImg=new Array(),stylenum=6;btn[0]="new";btn[1]="date";btn[2]="prev";btn[3]="next";btn[4]="search_btn";btn[5]="detail_close";btn[6]="browse";btn[7]="ok";for(u=0;u<btn.length;u++){img[img.length]=new Image();img[img.length-1].src=path+btn[u]+".gif";onImg[onImg.length]=new Image();onImg[onImg.length-1].src=path+btn[u]+"_on.gif";};for(u=0;u<stylenum;u++){img[img.length]=new Image();img[img.length-1].src=path+"t"+(u+1-0)+"/close.gif";img[img.length]=new Image();img[img.length-1].src=path+"t"+(u+1-0)+"/icon.gif";img[img.length]=new Image();img[img.length-1].src=path+"t"+(u+1-0)+"/l.gif";img[img.length]=new Image();img[img.length-1].src=path+"t"+(u+1-0)+"/t.gif";};function fGoto(){if(!Util.hasLoad){return false;};};function init(){Ajax.init();Dom.init();Util.init();Kind.init();Info.init();Input.init();var an=$("loading"),ak=window.screen.availHeight,av=window.screen.availWidth,aj=Util.loadHeight,au=Util.loadWidth,ed=Util.ed,ec=Util.ec;an.style.top=parseInt((ak-aj)/2)+"px";an.style.left=parseInt((av-au)/2)+"px";if(window.screen.height<768){$("search").style.display="none";};var p=$("searchInput");p.onfocus=function(){this.value="";};p.onblur=function(){if(this.value==""){this.value="输入姓名查找帖子";};};var bf=$("date_str"),c=new Date();Util.date=c;bf.innerHTML=c.getYear()+"年"+(c.getMonth()+1)+"月"+c.getDate()+"日";var dj=$("inputAdv");dj.style.display=Util.isAdv?"block":"none";if(!Util.isAdv){$("class").style.display="none";$("class_menu").style.display="none";var oLogo=$("logo");oLogo.style.cursor="hand";oLogo.onclick=function(){location.reload();};var k=document.createElement("DIV");k.className="class";k.innerHTML="<a href='http://www.chengtu.com' target='_blank'>返回最成都</a>";oLogo.appendChild(k);};$("date_str").innerHTML="";Util.hasLoad=true;};window.onerror=function(){return false;};
