var all_js_version="1.30";window.isIE=function(){if(document.frames){return true}else{return false}};document.getFrame=function(B){var A;if(document.frames){A=document.frames[B]}else{A=document.getElementById(B).contentWindow}return A};var Bbs={init:"",gotopage:function(B,A){var E;if(typeof (event)=="undefined"){var C=(Bbs.gotopage.caller);E=C.arguments[0]}else{E=event}var D=E.keyCode;if(D!=13){return }if(A==""){alert("请输入页码.");return false}window.location.href=B+"&pageid="+A},noCallback:function(){},doSearch:function(){var C=document.getElementById("so_keyword").value;var A=document.getElementById("so_nickname").value;var B=document.getElementById("so_range").value;var E=document.getElementById("so_title").checked;if(A=="输入昵称"){A=""}if(C=="输入关键字"){C=""}var D="";if(E){D="title:"}if(C!=""){D=D+C+" "}if(B!=""){D=D+B+" "}if(A!=""){D=D+"nickname:"+A}document.forms.so.q.value=D;return true},checkLogined:function(){return this.checkLoginedPostThread()},checkLoginedPostThread:function(){if(BoardConfig.isAllowGuestPostThread()){return true}if(!BbsCookie.isLogined()){this.showLoginDialog();return false}else{return true}},checkLogin:function(){return this.checkLoginedPostReply()},checkLoginedPostReply:function(){if(BoardConfig.isAllowGuestPostReply()){return true}if(!BbsCookie.isLogined()){this.showLoginDialog();return false}else{return true}},checkLoginedDownloadAttachment:function(){if(!BbsCookie.isLogined()){this.showLoginDialog();return false}else{return true}},loginCallback:null,showLoginDialog:function(E){if(typeof (E)=="boolean"&&E){var D=Bbs.showLoginDialog.caller;var A=D.arguments;var C=A.length;for(var B=0;B<A.length;B++){if(typeof (A[B])=="undefined"){C}}if(C==0){this.loginCallback=function(){D()}}else{if(C==1){this.loginCallback=function(){D(A[0])}}else{if(C==2){this.loginCallback=function(){D(A[0],A[1])}}else{if(C==3){this.loginCallback=function(){D(A[0],A[1],A[2])}}else{if(C==4){this.loginCallback=function(){D(A[0],A[1],A[2],A[3])}}else{alert("目前还不支持"+C+"个参数的方法");this.loginCallback=null}}}}}}else{this.loginCallback=E}Dialog.show("登录","/bbs/loginDialog.inc.html",true,true)},showLostDialog:function(){Bbs.loadDwr();Dialog.show("帖子丢失处理","/bbs/lostDialog.inc.html",true,true)},postArticle:function(A){if(!BbsCookie.isLogined()&&!BoardConfig.isAllowGuestPostThread()){this.showLoginDialog(true)}else{window.location.href="/bbs/post.jsp?boardid="+A}},postAsk:function(A){if(!BbsCookie.isLogined()){this.showLoginDialog(true)}else{window.location.href="/bbs/post.jsp?boardid="+A+"&icon=90"}},editArticle:function(B,C,A){if(!C){return this.editReply(B,A)}if(!BbsCookie.isLogined()){this.showLoginDialog(true)}else{Dwr.isLimitThread(B,A,function(D){if(D==true){alert("此贴已被限制编辑,请联系管理员取消限制.")}else{window.location.href="/bbs/post.jsp?boardid="+B+"&articleid="+A}})}},editReply:function(B,A){if(!BbsCookie.isLogined()){this.showLoginDialog(true)}else{window.location.href="/bbs/reply_edit.jsp?boardid="+B+"&articleid="+A}},logout:function(){var A="/bbs/user/logout.jsp?url=null";new Ajax.Request(A,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(C){try{var D="/bbs/user/logout_remote.jsp?url=null";new Ajax.Request(D,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(F){try{Userinfo.reloadUserinfo();BbsBoardAdmin.delCookie();webPopoLogout()}catch(E){}BbsUtil.reloadPage()}})}catch(B){}}})},checkDwr:function(){if(typeof (Dwr)=="undefined"){}},loadDwr:function(){if(1==1){return }if(typeof (Dwr)=="undefined"){this.loadJs("http://bbs.163.com/bbs/dwrinterfaceDwr.js");this.loadJs("http://bbs.163.com/bbs/dwrengine.js");this.loadJs("http://bbs.163.com/bbs/dwrutil.js")}},loadJs:function(B){var A=document.createElement("script");A.src=B;if(document.frames){document.body.insertAdjacentElement("BeforeBegin",A)}else{document.body.appendChild(A)}},loadCss:function(A){var B=document.getElementsByTagName("HEAD").item(0);var C=document.createElement("link");C.href=A;C.rel="stylesheet";C.type="text/css";B.appendChild(C)},showMessage:function(A){if(typeof (A)=="undefined"){A=1}BbsAdmin.showDialog("我的纸条","/bbs/dialog/msg_list.jsp?pageid="+A);Dialog.setWidth(600);if(A==1){Userinfo.reloadUserinfo()}},showSentMessage:function(A){if(typeof (A)=="undefined"){A=1}BbsAdmin.showDialog("已发送纸条","/bbs/dialog/msg_sent_list.jsp?pageid="+A);Dialog.setWidth(600)},showMyBlackList:function(A){if(typeof (A)=="undefined"){A=1}BbsAdmin.showDialog("黑名单","/bbs/dialog/my_blacklist.jsp?pageid="+A);Dialog.setWidth(600)},addMyBlackList:function(A){if(typeof (A)=="undefined"){A=""}BbsAdmin.showDialog("添加黑名单","/bbs/dialog/my_blacklist_add.jsp?userid="+A);Dialog.setWidth(600)},sendMessage:function(A){if(typeof (A)=="undefined"){A=""}BbsAdmin.showDialog("发送纸条","/bbs/dialog/msg_write.jsp?userid="+A);Dialog.setWidth(600)},sendSysMessage:function(A){if(typeof (A)=="undefined"){A=""}BbsAdmin.showDialog("发送系统纸条","/bbs/dialog/msg_sys_write.jsp?userid="+A);Dialog.setWidth(600)},delMessage:function(A,B){Dwr.delMessage(B,function(C){Bbs.showMessage(A)})},delSentMessage:function(A,B){Dwr.delSentMessage(B,function(C){Bbs.showSentMessage(A)})},delBlackList:function(A,B){Dwr.delBlackList(B,function(C){Bbs.showMyBlackList(A)})},getChannel:function(){var B=window.location.host;var A=B.replace(/(.*?)([a-z0-9]+)\.163\.com/gi,"$2");if("bbs"==A){A="ntes"}else{if("money"==A){A="stock"}else{if("tech"==A){if("club.tech.163.com"==B){A="mobile"}else{if("digibbs.tech.163.com"==B){A="digi"}}}else{if("cbachina"==A){A="sports"}}}}return A},loginPassport:function(C,A,B){if(C==""){return"还没有输入通行证帐号."}if(A==""){return"还没有输入密码."}Dwr.loginPassport(C,A,function(D){if(D.indexOf("success")==-1){alert(D);return }Dialog.close();var E;if(B==null||typeof (B)=="undefined"){E=Bbs.loginCallback}else{E=B}if(E!=null&&(typeof (E)=="function"||typeof (E)=="object")){E();Userinfo.loadUserinfo()}})},getReplyBody:function(C,A){var B="";DWREngine.setAsync(false);Dwr.getReplyBody(C,A,function(D){B=D});DWREngine.setAsync(true);return B},showPostMenu:function(A){var B=$("post_menu_"+A);if(B==null){alert("菜单不存在.");return }B.style.display=(B.style.display=="block")?"none":"block"},showMyFavorite:function(B){if(!BbsCookie.isLogined()){this.showLoginDialog(BbsUtil.reloadPage);return }else{var A=$(B);A.style.display="block";this.loadMyFavorite(B)}},loadMyFavorite:function(B){var A="/bbs/my_favorite.inc.jsp";new Ajax.Request(A,{onComplete:function(D){var C=(D.responseText);if(D.status==200){$(B).innerHTML=C}else{alert("请求出错.")}}})},showOnlineStatus:function(A){var B=document.getElementById("onlinestatus");if(B!=null){if(A=="1"){B.innerHTML="在线"}else{B.innerHTML="离线"}}},getOnlineStatus:function(username){var url="/bbs/dialog/userinfo.jsp?reload=true&username="+username;new Ajax.Request(url,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(data){eval(obj.responseText)}})},applymaster:function(A){if(!BbsCookie.isLogined()){alert("请先登录.");return }BbsAdmin.showDialog("版主申请","/bbs/applydata.jsp?boardid="+A);Dialog.setWidth(650)},addApplyMaster:function(G){if(!BbsCookie.isLogined()){alert("请先登录.");return }var H=BbsCookie.getPassport();var E=document.forms.frmapplymaster;var F=E.reason.value;var D=E.name.value;var A=E.im.value;var C=E.mobile.value;var B=E.email.value;if(F==""){alert("请填写申请原因.");E.reason.focus();return }if(D==""){alert("请填你的名字.");E.name.focus();return }if(A==""){alert("请填QQ/MSN/POPO.");E.im.focus();return }if(C==""){alert("请填写联系电话.");E.mobile.focus();return }if(B==""){alert("请填写Email.");E.email.focus();return }Dwr.addApplyMaster(G,D,F,A,C,B,function(I){alert(I);location.href="/bbs/applysuccess.jsp?boardid="+G})}};var Thread={init:"",sleeping:false,ok:function(){document.title="sleep:ok";this.sleeping=true;var A=(this.arguments.length);if(A==0){Thread.func()}else{if(A==1){Thread.func(this.arguments[0])}else{if(A==2){Thread.func(this.arguments[0],this.arguments[1])}else{if(A==3){Thread.func(this.arguments[0],this.arguments[1],this.arguments[2])}else{alert("使用sleep不能超过3个参数")}}}}Thread.func=null},func:null,"arguments":null,sleep:function(A){document.title="sleep:"+A;if(this.sleeping){this.sleeping=false;return false}else{this.sleeping=true}this.func=this.sleep.caller;this.arguments=this.func.arguments;setTimeout("Thread.ok()",A);return true}};var BbsUtil={init:"",checkUploadImg:function(A){if(A==null||A==""){alert("请先选择文件");return false}else{if(!this.isImg(A)){alert("上传的图片的格式只能是gif、jpg/jpeg或者png");return false}}return true},isImg:function(A){var B=/\.(gif|jpg|png|jpeg)$/i;if(B.test(A)){return true}else{return false}},checkDomain:function(B){try{if(document.domain!=B){var C=document.location.href;var D=C.replace(document.domain,B);var A=new Image();A.src="http://fund8.money.163.com/bbs/class_not_found.jsp?message=错误域名:"+document.referrer;document.location.href=D}}catch(E){}},showLoginButton:function(){var C="";if(BbsCookie.isLogined()){C+=('<span style="line-height:24px">');C+=(' <a href="javascript:BbsBoardAdmin.checkMaster()" target="_self" id="boardadmin">管理模式</a>');C+=' <a href="/bbs/list.jsp?boardid='+global_boardid+"&plugin=y&username="+BbsCookie.getPassport()+'" title="我在当前版面发表的帖子">我的帖子</a> ';var A=Userinfo.getMessageCount();if(A>0){var B=18;var F=-30;if(!window.isIE()){B=0;F=90}C+=('<div style="position:absolute"><div style="height:20px;width:120px;position:relative;left:'+F+"px;top:"+B+'px;background-color:#FFFFE1;border:1px solid #858585;color:#333333;font-size:13px;padding:1px;text-align:center;"><a href="javascript:Bbs.showMessage()" target="_self">您有<strong>'+A+"</strong>条新纸条</a></div></div>")}C+=(' <a href="javascript:Bbs.showMessage()" target="_self">查看纸条</a>');C+=(' <a href="javascript:Bbs.logout()" target="_self">退出</a></span>')}else{C+=('<a href="javascript:Bbs.showLoginDialog(BbsUtil.reload)" target="_self"><img src="/bbs/img07/btbg02.gif" width="87" height="22" alt="登录论坛" /></a>')}var E=document.getElementById("myLoginButton");E.innerHTML=C;try{BbsBoardAdmin.load()}catch(D){}},showLoginInfo:function(){var D=document.getElementById("myLoginInfo");if(D==null){return this.showLoginButton()}var C="";if(BbsCookie.isLogined()){if(typeof (noNicknameInfo)=="undefined"){var F=BbsCookie.getPassport();C+=('<a class="cRed" href="http://bbs.163.com/'+F+'" target="_blank">'+Userinfo.getNickname()+"</a> 欢迎来到网易！")}var A=Userinfo.getMessageCount();if(A>0){var B=18;var E=-30;if(!window.isIE()){B=0;E=90}C+=('<div style="position:absolute"><div style="height:14px;width:120px;position:relative;left:'+E+"px;top:"+B+'px;background-color:#FFFFE1;border:1px solid #858585;color:#333333;font-size:13px;padding:3px;text-align:center;"><a href="javascript:Bbs.showMessage()" target="_self" style="text-decoration:none;color:#000">您有<strong>'+A+"</strong>条新纸条</a></div></div>")}C+=('<span id="mymsg">您有<a href="javascript:Bbs.showMessage()" target="_self" class="cRed">'+A+"</a>个未读纸条 </span>");C+=('<a href="javascript:Bbs.logout()" target="_self" class="c1">安全退出</a>')}else{C+=('<a class="cRed">游客</a> 欢迎来到网易！请先<a href="javascript:Bbs.showLoginDialog(Bbs.noCallback)" target="_self" class="c1">登陆</a>')}D.innerHTML=C},copyText:function(B){try{clipboardData.setData("Text",B)}catch(A){alert("“复制到剪贴板功能”还不兼容您使用的浏览器.")}},format:function(B){var A="\n"+B.value;A=A.replace(/ |　/ig,"");A=A.replace(/\r\n/ig,"\n");A=A.replace(/\n\n/ig,"\n");A=A.replace(/\n\n/ig,"\n");A=A.replace(/\n\n/ig,"\n");A=A.replace(/\n\n/ig,"\n");A=A.replace(/\n/ig,"\n\n　　");A=A.replace("\n\n","");B.value=A},getCodeJsp:function(){var B=new Date().getTime();var A=B%10;return"/bbs/code/code"+A+".jsp"},reloadCode:function(){document.getElementById("imgcheckcode").src=BbsUtil.getCodeJsp()+"?"+(new Date().getTime())},loadCheckcode:function(C){var B=document.forms.frmpost;var A=B.checkcode;if(typeof (A)=="object"){if(A.value==""){this.reloadCheckcode()}}},reloadCheckcode:function(A){if(typeof (A)=="undefined"){A="imgcheckcode"}document.getElementById(A).src=BbsUtil.getCodeJsp()+"?"+(new Date().getTime())},checkReplyPost:function(){var D=document.forms.frmpost;if(typeof (isyiba)!="undefined"&&isyiba=="yiba"&&typeof (filename)!="undefined"&&filename=="list"){if(D.title.value==""){alert("帖子标题不能为空哦.");D.title.focus();return false}}if(D.content.value==""){alert("内容不能为空哦.");D.content.focus();return false}if(1==1){var C=D.checkcode;if(typeof (C)=="object"){if(C.value==""){alert("验证码还没有输入.");C.focus();return false}if(C.value.length!=4){alert("验证码的位数不对哦.");C.focus();return false}}else{var A="";if(BbsCookie.isLogined()){A=this.isWantVerify()}else{A="您是匿名发帖，需要输入验证码."}if(A!=""){var B="";if(typeof (isyiba)!="undefined"&&isyiba=="yiba"){B='<span class="item">验 证 码：</span> <input style="width:70px" type="text" name="checkcode" id="textfield" onkeydown="if(event.keyCode==13){if(BbsUtil.checkReplyPost() != false && Editor.insertImgorMedia() != false){document.frmpost.submit();}}"/><a href="javascript:BbsUtil.reloadCode();"><span class="cGray">&nbsp;点击更换验证码&nbsp;</span></a><span class="cDRed">'+A+'</span><br/>　　　　　　　　 <a href="javascript:BbsUtil.reloadCode();"><img id="imgcheckcode" src="'+BbsUtil.getCodeJsp()+'" alt="看不清，换一张" /></a><br/>　　　　　　　　 　　<a href="javascript:BbsUtil.reloadCode();">看不清，换一张</a>'}else{B='<div>验证码:　　　<input type="text" size="6" name="checkcode" value="" class="input007" maxlength="4"/>,您发表回复需要输入验证码。(<font color="#ff0000">'+A+'</font>)<br/>　　　　　　<a href="javascript:BbsUtil.reloadCode();" target="_self"><img id="imgcheckcode" src="'+BbsUtil.getCodeJsp()+'" alt="看不清，换一张"/></a><br/>　　　　　　　　<a href="javascript:BbsUtil.reloadCode();" target="_self">看不清，换一张</a></div>'}new Insertion.Before("frmpost_upload",B);D.checkcode.focus();return false}}}document.getElementById("btnSubmit").style.visibility="hidden";Dwr.hasForfendKeyword(global_boardid,global_threadid,"",D.content.value,function(E){if(E==true){BbsAdmin.showDialog("严禁词","/bbs/dialog/hasforfend.jsp?boardid="+global_boardid+"&threadid="+global_threadid);document.getElementById("dialog_close_btn").style.display="none"}else{Dwr.hasSubtleKeyword(global_boardid,global_threadid,"",D.content.value,function(F){if(F==true){BbsAdmin.showDialog("敏感词","/bbs/dialog/hassubtle.jsp?boardid="+global_boardid+"&threadid="+global_threadid)}else{document.getElementById("btnSubmit").style.visibility="hidden";if(typeof (isyiba)=="undefined"){D.submit();return false}else{return true}}})}});if(typeof (isyiba)=="undefined"){return false}else{return true}},ajaxpaging:function(A,C,B){new Ajax.Request(A,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(D){$(C).innerHTML=D.responseText}})},setAnymousePost:function(){var C=document.forms.frmpost;if(typeof (checkcode)=="object"){return }this.unsetAnymousePost();var A="您是匿名发帖，需要输入验证码.";var B='<span class="item">验 证 码：</span> <input type="text" name="checkcode" id="textfield" /><span class="cGray">请输入验证码。</span><span class="cDRed">'+A+'</span><br/><a href="javascript:BbsUtil.reloadCode();"><img id="imgcheckcode" src="'+BbsUtil.getCodeJsp()+'" alt="看不清，换一张" /></a>';document.getElementById("frmpost_upload").innerHTML=B;C.checkcode.focus()},unsetAnymousePost:function(){document.getElementById("frmpost_upload").html="";document.getElementById("frmpost_upload").style.display="none"},showAnonymouseDiv:function(){if(BbsCookie.isLogined()){document.getElementById("setAnonymous").style.display="block"}else{document.getElementById("setAnonymous").style.display="none"}},showorhideDiv:function(A){theDiv=document.getElementById(A);if(theDiv==null||theDiv=="undefined"){return }if(theDiv.style.display=="none"){theDiv.style.display="block"}else{theDiv.style.display="none"}},isWantVerify:function(){var B=document.forms.frmpost;DWREngine.setAsync(false);var A="";Dwr.isWantVerify(global_boardid,function(C){A=C});DWREngine.setAsync(true);return A},isChecked:function(A){if(typeof (A.length)=="undefined"){return A.checked}for(var B=0;B<A.length;B++){if(A[B].checked){return true}}return false},getRadioValue:function(F,B){var D=document.forms[F];var A=D[B];var E=null;if(typeof (A)!="undefined"){for(var C=0;C<A.length;C++){if(A[C].checked){E=A[C].value}}}return E},getSelectValue:function(E,A){var B=document.forms[E];var D=B[A];var C=null;if(typeof (D)!="undefined"){C=D.value}return C},getCheckboxValue:function(E,A){var B=document.forms[E];var D=B[A];var C=0;if(typeof (D)!="undefined"){if(D.checked){C=1}}return C},getValues:function(G,D){var F=document.forms[G];var A=F[D];var B=new Array();var C=-1;for(var E=0;E<A.length;E++){if(A[E].type=="checkbox"||A[E].type=="radio"){if(A[E].checked){C++;B[C]=A[E].value}}else{C++;B[C]=A[E].value}}return B},addFavorite:function(){window.external.addFavorite(document.location.href,document.title)},inputFocus:function(A){if(A.title==""){A.title=A.value;A.onfocus=function(){if(this.value==this.title){this.value=""}};A.onblur=function(){if(this.value==""){this.value=this.title}}}A.value=""},getBoardName:function(B){DWREngine.setAsync(false);var A=null;Dwr.getBoardName(B,function(C){A=C});DWREngine.setAsync(true);return A},getBytes:function(B){if(B==null){return 0}var A=0;for(i=0;i<B.length;i++){var C=B.charCodeAt(i);if((C>=0&&C<=255)||(C>=65377&&C<=65439)){A+=1}else{A+=2}}return A},reload:function(){window.location.reload()},reloadPage:function(){location.href=location.href},noreload:function(B){var A=document.getElementById(B);A.style.display="none"},imageZoom:function(A){var C=$("content_"+A);var D=C.getElementsByTagName("IMG");for(var B=0;B<D.length;B++){if(D[B].width>600){D[B].width=600}}},imgZoom:function(D,A){if(D.width>600){D.width=600}if(!A){return }var B=D.parentNode;if(B.tagName.toLowerCase()!="a"){var C=document.createElement("a");C.href=D.src;C.target="_blank";B.insertBefore(C,D);C.appendChild(D)}},trim:function(A){return A.replace(/(^\s*)|(\s*$)/g,"")},showDiv:function(A,C,B){if(A=="undefined"){return }if(C==null||C=="undefined"){return }if($(B)==null||$(B)=="undefined"){return }clearTimeout(A);C.onmouseout=function(){A=setTimeout("BbsUtil.hideDiv('"+B+"')",100)};$(B).style.display="block";$(B).onmouseover=function(){clearTimeout(A);$(B).style.display="block"};$(B).onmouseout=function(){BbsUtil.hideDiv(B)}},hideDiv:function(A){if($(A)==null||$(A)=="undefined"){return }$(A).style.display="none"},subStringByByte:function(A,C){var D="";var B=0;for(i=0;i<A.length;i++){if(A.charCodeAt(i)>255){B+=2}else{B++}if(B>C){return D}D+=A.charAt(i)}return A},checkTextNum:function(C,E,D){if(C!=null&&D!=null){var A=this.getBytes(C.value);var B=((E-A)/2);if(B<0){C.value=this.subStringByByte(C.value,E);B=0}D.innerHTML=B}},copyTitle:function(C){var A=window.document.location.href;A+="\r\n"+C;try{clipboardData.setData("Text",A);alert("您已成功复制本贴标题和链接地址，欢迎您推荐给您的朋友！")}catch(B){alert("“复制到剪贴板功能”还不兼容您使用的浏览器.")}},copyToClipBoard:function(B,D){var A=window.document.location.href;var C=A;if(D!=null||D!=""){C+="\r\n"+D}this.copy_clip(C);$(B).innerHTML="复制成功请推荐给您的好友";Dwr.copyUrl(D,A,function(E){})},copy_clip:function(A){if(window.clipboardData){window.clipboardData.setData("Text",A)}else{var C="flashcopier";if(!document.getElementById(C)){var D=document.createElement("div");D.id=C;document.body.appendChild(D)}document.getElementById(C).innerHTML="";var B='<embed src="http://swf.news.163.com/2008/clipBoard.swf?data='+A+'" width="0" height="0" type="application/x-shockwave-flash"></embed>';document.getElementById(C).innerHTML=B}return true}};var Userinfo={init:"",userinfo:null,getUrl:function(){var A="/bbs/dialog/userinfo.jsp?username="+BbsCookie.getPassport();return A},loadUserinfo:function(){if(this.userinfo==null){var A=BbsCookie.getPassport();if(BbsCookie.isLogined()&&A!=""&&A!=null){Bbs.loadJs(this.getUrl())}else{BbsUtil.showLoginInfo()}}},reloadUserinfo:function(){this.userinfo=null;var A=this.getUrl();new Ajax.Request(A,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(B){Userinfo.loadUserinfo()}})},removeUserinfo:function(){this.userinfo=null;var A=this.getUrl();new Ajax.Request(A,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(B){}})},getUserinfo:function(){if(this.userinfo==null){return{}}else{return this.userinfo}},setUserinfo:function(A){this.userinfo=A},updateNickname:function(B,A){Dwr.updateNickname(B,A)},getNickname:function(){var A=this.getUserinfo().nickname;if(A==null||A==""){A=BbsCookie.getPassport()}return A},getMessageCount:function(){var A=this.getUserinfo().messageCount;if(A==null||A==""){return"0"}else{return A}}};var Editor={init:"",dopost:function(){if(1==1){try{var A=plugin_submit_before();if(A==false){return false}}catch(C){}}if(this.validate()==false){return false}else{try{var A=plugin_submit();if(A==false){return false}}catch(C){}var B=this.getForm();if(B.isautocopy.checked){BbsUtil.copyText(B.content.value)}Dwr.hasForfendKeyword(global_boardid,global_threadid,"",B.content.value,function(D){if(D==true){BbsAdmin.showDialog("严禁词","/bbs/dialog/hasforfend.jsp?boardid="+global_boardid+"&threadid="+global_threadid);document.getElementById("dialog_close_btn").style.display="none"}else{Dwr.hasSubtleKeyword(global_boardid,global_threadid,"",B.content.value,function(E){if(E==true){BbsAdmin.showDialog("敏感词","/bbs/dialog/hassubtle.jsp?boardid="+global_boardid+"&threadid="+global_threadid)}else{B.submit();document.getElementById("btnSubmit").style.visibility="hidden"}})}});return false}},formname:"frmpost",setFormName:function(A){if(A==null||A==""||typeof (A)=="undefined"){this.formname="frmpost"}else{this.formname=A}},getForm:function(){return document.forms[this.formname]},getContentObject:function(){return document.forms[this.formname].content},validate:function(){var C=this.getForm();if(1==1){var B=(document.forms.frmpost.cid);if(typeof (B)=="object"){if(!BbsUtil.isChecked(B)){alert("您还未选择帖子的类别,请在帖子标题下方选择.");return false}}}if(C.title.value==""){alert("随便在标题框输入点什么吧.");C.title.focus();return false}if(C.content.value==""){alert("发贴不能不填内容的哦,^_^");C.content.focus();return false}if(1==1){var A=C.checkcode;if(typeof (A)=="object"){if(A.value==""){alert("验证码还没有输入.");A.focus();return false}if(A.value.length!=4){alert("验证码的位数不对哦.");A.focus();return false}}}},insertFace:function(A){this.insertContent("[face]"+A+"[/face]")},showFaceDialog:function(){Dialog.show("插入表情","/bbs/dialog/face.jsp",false,false)},changeIcon:function(B){var A="http://bbs.163.com/bbs/icon/face/"+B+".gif";$("img_icon").src=A;$("icon").value=B;Dialog.close()},getIcon:function(){return $("icon").value},showIconDialog:function(){var A=this.getIcon();if(A>=90){alert("此类型帖子不支持表情修改.");return }Dialog.show("设置表情","/bbs/dialog/icon.jsp",false,false);return true},insertContent_bak:function(A){if(A==null||A==""){alert("没有需要添加的内容！");return }this.getForm().content.value+=A},insertContent:function(D,H){this.focus();var G=this.getForm().content;if(document.selection){H=false;if(H){var B=document.selection.createRange();B.text=this.replacement(D,B.text)}else{G.value+=this.replacement(D,"")}}else{var E=G.value;var F=E.substring(0,G.selectionStart);var C=E.substring(G.selectionEnd);var A=(E.substring(G.selectionStart,G.selectionEnd));G.value=F+this.replacement(D,A)+C}},openme:function(A){A.style.background="#CCCCCC"},closeme:function(A){A.style.background=""},focus:function(){this.getForm().content.focus()},onBold:function(){var B="[b]$text[/b]";var A="请在内容框选中要加粗的文字，要不我不知道该做什么.";this.selection(B,A)},onItalic:function(){var B="[i]$text[/i]";var A="请在内容框选中要倾斜的文字，要不我不知道该做什么.";this.selection(B,A)},onUnderline:function(){var B="[u]$text[/u]";var A="请在内容框选中要加下划线的文字，要不我不知道该做什么.";this.selection(B,A)},hasSelection:function(){this.focus();var C=this.getForm().content;if(document.selection){var A=document.selection.createRange();if(A.text){return true}else{return false}}else{var B=C.value;if(C.selectionStart<C.selectionEnd){return true}else{return false}}},selection:function(E,D){this.focus();var H=this.getForm().content;if(document.selection){var B=document.selection.createRange();if(B.text){B.text=this.replacement(E,B.text)}else{alert(D)}}else{var F=H.value;if(H.selectionStart<H.selectionEnd){var G=F.substring(0,H.selectionStart);var C=F.substring(H.selectionEnd);var A=(F.substring(H.selectionStart,H.selectionEnd));H.value=G+this.replacement(E,A)+C}else{alert(D)}}},replacement:function(A,B){var C=A.replace(/\$text/g,B);return C},insertHyperLink:function(){var A=prompt("请输入超链接地址):","http://");if((A!=null)&&(A!="http://")){if(this.hasSelection()){var C='[url="'+A+'"]$text[/url]';var B="您没有选中内容.";this.selection(C,B)}else{this.getForm().content.value=this.getForm().content.value+"[url]"+A+"[/url]"}}},insertImgorMedia:function(){var B=this.getForm();var D=BbsUtil.trim(B.insertinput.value);if(D==""||D=="http://"){document.getElementById("btnSubmit").style.visibility="";return }var A="";var C=this.getMediaType(D);if(C=="gif"||C=="jpg"||C=="jpeg"||C=="png"){A="[img]"+D+"[/img]"}else{if(C=="wmv"||C=="wma"||C=="mp3"){if(BbsBoardAdmin.isMaster()==false){alert("您不是本吧吧主，不能发表带视频、音频的帖子！");document.getElementById("btnSubmit").style.visibility="";return false}else{A='\n[media width="320" height="260"]'+D+"[/media]\n"}}else{if(C=="rm"){if(BbsBoardAdmin.isMaster()==false){alert("您不是本吧吧主，不能发表带视频、音频的帖子！");document.getElementById("btnSubmit").style.visibility="";return false}A='\n[rm width="320" height="260"]'+D+"[/rm]\n"}else{if(C=="swf"){if(BbsBoardAdmin.isMaster()==false){alert("您不是本吧吧主，不能发表带视频、音频的帖子！");document.getElementById("btnSubmit").style.visibility="";return false}A='\n[swf width="320" height="260"]'+D+"[/swf]\n"}else{alert("输入的网址不合法，支持的格式图片：gif,jpg,jpeg,png；视频：mp3,wma,wmv,rm,swf");B.insertinput.focus();document.getElementById("btnSubmit").style.visibility="";return false}}}}B.content.value+="\n"+A+"\n";B.insertinput.value="http://"},insertImg:function(){var B=this.getForm();if(B.insertimg.value==""){alert("请填写图片地址！");return }var A="[img]"+B.insertimg.value+"[/img]";this.insertContent(A);B.insertimg.value=""},insertImage:function(){var A=prompt("输入图片的超链接):","http://");if((A!=null)&&(A!="http://")){var B="[img]"+A+"[/img]";this.insertContent(B,true)}},insertMedia:function(){if(!BbsCookie.isLogined()){alert("您还没有登录，请先登录.");return }BbsAdmin.showDialog("插入视频","/bbs/dialog/insert_media.jsp?boardid="+global_boardid)},insertRm:function(){if(!BbsCookie.isLogined()){alert("您还没有登录，请先登录.");return }BbsAdmin.showDialog("插入视频","/bbs/dialog/insert_rm.jsp?boardid="+global_boardid)},insertVote:function(){if(!BbsCookie.isLogined()){alert("您还没有登录，请先登录.");return }var D=0;if(1==1){var C=this.getForm().content.value;var B=/\[plugin:vote\]([0-9]+)\[\/plugin:vote\]/gi;var A=new RegExp(B).exec(C);if(A!=null){D=parseInt(A[1])}}if(D<=0){BbsAdmin.showDialog("插入投票","/bbs/plugin/vote_post.jsp?boardid="+global_boardid)}else{BbsAdmin.showDialog("修改投票("+D+")","/bbs/plugin/vote_post.jsp?boardid="+global_boardid+"&id="+D)}Dialog.setWidth(460)},insertAttachment:function(){if(!BbsCookie.isLogined()){alert("您还没有登录，请先登录.");return }var D=0;if(1==1){var C=this.getForm().content.value;var B=/\[plugin:attachment\]([0-9]+)\[\/plugin:attachment\]/gi;var A=new RegExp(B).exec(C);if(A!=null){D=parseInt(A[1])}}if(D<=0){BbsAdmin.showDialog("插入附件","/bbs/plugin/attachment_post.jsp?boardid="+global_boardid)}else{BbsAdmin.showDialog("修改附件("+D+")","/bbs/plugin/attachment_post.jsp?boardid="+global_boardid+"&id="+D)}Dialog.setWidth(460)},insertHtml:function(){if(!BbsCookie.isLogined()){alert("您还没有登录，请先登录.");return }var D=0;if(1==1){var C=this.getForm().content.value;var B=/\[plugin:html\]([0-9]+)\[\/plugin:html\]/gi;var A=new RegExp(B).exec(C);if(A!=null){D=parseInt(A[1])}}if(D<=0){BbsAdmin.showDialog("插入HTML","/bbs/plugin/html_post.jsp?boardid="+global_boardid)}else{BbsAdmin.showDialog("修改HTML","/bbs/plugin/html_post.jsp?boardid="+global_boardid+"&id="+D)}Dialog.setWidth(600)},html2ubb:function(A){A=A.replace(/\r/g,"");A=A.replace(/on(load|click|dbclick|mouseover|mousedown|mouseup)="[^"]+"/ig,"");A=A.replace(/<script[^>]*?>([\w\W]*?)<\/script>/ig,"");A=A.replace(/<a[^>]+href="([^"]+)"[^>]*>(.*?)<\/a>/ig,'\n[url="$1"]$2[/url]\n');A=A.replace(/<font[^>]+color=([^ >]+)[^>]*>(.*?)<\/font>/ig,'\n[color="$1"]$2[/color]\n');A=A.replace(/<img[^>]+src="([^"]+)"[^>]*>/ig,"\n[img]$1[/img]\n");A=A.replace(/<([\/]?)b>/ig,"[$1b]");A=A.replace(/<([\/]?)strong>/ig,"[$1b]");A=A.replace(/<([\/]?)u>/ig,"[$1u]");A=A.replace(/<([\/]?)i>/ig,"[$1i]");A=A.replace(/&nbsp;/g," ");A=A.replace(/&amp;/g,"&");A=A.replace(/&quot;/g,'"');A=A.replace(/&lt;/g,"<");A=A.replace(/&gt;/g,">");A=A.replace(/<br>/ig,"\n");A=A.replace(/<[^>]*?>/g,"");A=A.replace(/\[url=([^\]]+)\]\n(\[img\]\1\[\/img\])\n\[\/url\]/g,"$2");A=A.replace(/\n+/g,"\n");return A},paste:function(){if(!window.isIE()){alert("该功能只能在IE下使用.");return }var B=document.getFrame("rtf");B.focus();B.document.body.innerHTML="";B.document.execCommand("paste");var C=B.document.body.innerHTML;if(C.length==0){alert("剪切版不存在超文本数据！");return""}var A=this.html2ubb(C);this.insertContent(A)},initPaste:function(){if(window.isIE()){document.getFrame("rtf").document.designMode="On";document.getElementById("rtf").style.display="";document.getElementById("btnPaste").style.display=""}},isEditing:function(){var A=parseInt(this.getForm()["articleid"].value);return(A>0)},voteChangeOptions:function(){var D=document.forms.frminsertvote;var A=D.num.value;var E=$("vote_options");var C=E.childNodes.length;if(A>=100){alert("选项数量最大99个.");return }else{if(A<2){alert("选项数量最小2个.");return }}if(A<C){if(!confirm("选项里的内容会被删除，提交后将永久被删除，是否确认减少选项操作？")){return }for(var B=C;B>A;B--){this.voteDelOptions()}}else{for(var B=C;B<A;B++){this.voteAddOptions()}}},voteAddOptions:function(){var D=$("vote_options");var A=D.childNodes;var B=A.length+1;var C="<li>选项"+(B<10?"0"+B:B)+'：<input name="options" size="48" type="text" value=""/></li>';new Insertion.Bottom("vote_options",C)},voteDelOptions:function(){var C=$("vote_options");var A=C.childNodes;var B=A.length-1;C.removeChild(A[B])},getMediaType:function(B){var A=B.split(".");if(A==null||A.length<=0){return""}return A[A.length-1].toLowerCase()},setKeyValue:function(){if(!(event.shiftKey||event.altKey)&&event.keyCode==13&&event.ctrlKey){this.dopost()}}};var BbsCookie={init:"",getValue:function(A){},getCookieValue:function(B){var A=document.cookie.indexOf(";",B);if(A==-1){A=document.cookie.length}return unescape(document.cookie.substring(B,A))},getCookie:function(D){var B=D+"=";var F=B.length;var A=document.cookie.length;var E=0;while(E<A){var C=E+F;if(document.cookie.substring(E,C)==B){return this.getCookieValue(C)}E=document.cookie.indexOf(" ",E)+1;if(E==0){break}}return null},getExpires:function(B){var A=new Date();A.setTime(A.getTime()+B);return A},deleteCookie:function(A){this.setCookie(A,"",0)},setCookie:function(B,C,A){var C=B+"="+escape(C)+"; domain=163.com";if(A>0){C+=" expires="+this.getExpires(A).toGMTString()}document.cookie=C},getPassport:function(){var B=this.getCookie("NETEASE_SSN");if(B==null){return this.getPassport2()}var A=B.indexOf("@163.com");if(A==-1){return B}else{return B.substring(0,A)}},getPassport2:function(){var B=this.getCookie("P_INFO");if(B==null){return""}if(1==1){var A=B.indexOf("|");if(A>-1){B=B.substring(0,A)}}var A=B.indexOf("@163.com");if(A==-1){return B}else{return B.substring(0,A)}},isLogined:function(){var B=BbsCookie.getCookie("NTES_SESS");var A=(B!=null&&B!="");if(!A){return this.isLogined2()}var C=BbsCookie.getPassport();A=(C!=null&&C!="");return A},isLogined2:function(){var D=BbsCookie.getCookie("S_INFO");var F=(D!=null&&D!="");if(!F){return false}var B=-1;if(1==1){var C=D.indexOf("|");if(C>-1){B=D.substring(0,C)}}var E=BbsCookie.getPassport();var A=(E!=null&&E!="");return A}};var BbsAdmin={init:"",showDialog:function(B,A){Bbs.loadDwr();if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true)}else{Dialog.show(B,A,false,false)}},showIP:function(C,B,A){if(A=="-0000"){this.showDialog("查看IP","/bbs/dialog/showip.jsp?boardid="+C+"&articleid="+B)}else{this.showDialog("查看用户","/bbs/dialog/addBlackUser.jsp?boardid="+C+"&articleid="+B+"&userid="+A)}},topThread:function(B,A){this.showDialog("置顶帖子","/bbs/dialog/topthread.jsp?boardid="+B+"&threadid="+A)},pushThread:function(B,A){this.showDialog("推荐帖子","/bbs/dialog/pushthread.jsp?boardid="+B+"&threadid="+A)},eliteThread:function(B,A){this.showDialog("帖子加精华","/bbs/dialog/elitethread.jsp?boardid="+B+"&threadid="+A)},insertGuide:function(B,A){this.showDialog("插入导读","/bbs/dialog/insertguide.jsp?boardid="+B+"&threadid="+A);Dialog.setWidth(550)},limitThread:function(B,A){this.showDialog("限制编辑帖子","/bbs/dialog/limitthread.jsp?boardid="+B+"&threadid="+A)},lockThread:function(B,A){this.showDialog("帖子加锁","/bbs/dialog/lockthread.jsp?boardid="+B+"&threadid="+A)},rubbishThread:function(B,A){this.showDialog("垃圾帖子","/bbs/dialog/rubbishthread.jsp?boardid="+B+"&threadid="+A)},reply:function(F,E,D,A){if(!Bbs.checkLoginedPostReply()){return }if($("div_reply").style.display=="none"){alert("当前帖子不允许发表评论.");new Ajax.Request("/bbs/checkreply.jsp",{method:"get"});return }var C="【回复";if(D>0){C+=D+"楼"}C+=" "+A+" 】:\n";$("frmpost_toolbar").style.display="block";$("frmpost_upload").style.display="block";var B=document.getFrame("frmupload");if(typeof (B)=="object"){B.setUploadBoardid(global_boardid)}document.forms.frmpost.content.focus();document.forms.frmpost.content.value=C;document.documentElement.scrollTop=600000},quoteReply:function(C,B){if($("div_reply").style.display=="none"){alert("当前帖子不允许发表评论.");new Ajax.Request("/bbs/checkreply.jsp",{method:"get"});return }if(!Bbs.checkLoginedPostReply()){return }var A="/bbs/dialog/quotereply.jsp?boardid="+C+"&articleid="+B;new Ajax.Request(A,{onComplete:function(F){var E=(F.responseText);E=E.replace(/\n\s*\r/g,"");if(F.status==200){$("frmpost_toolbar").style.display="block";$("frmpost_upload").style.display="block";var D=document.getFrame("frmupload");if(typeof (D)=="object"){D.setUploadBoardid(global_boardid)}document.forms.frmpost.content.focus();document.forms.frmpost.content.value=E;document.documentElement.scrollTop=600000}else{alert("请求出错.")}}})},sayGood:function(B,A){Dwr.sayGood(B,A,function(C){var E=C;if(E.indexOf("错误:")==-1){var D=document.getElementById("text"+A+"_goodnum");D.innerHTML=parseInt(D.innerHTML)+1}})},sayBad:function(B,A){Dwr.sayBad(B,A,function(C){var E=C;if(E.indexOf("错误:")==-1){var D=document.getElementById("text"+A+"_badnum");D.innerHTML=parseInt(D.innerHTML)+1}})},delPost:function(B,A){this.showDialog("删除帖子","/bbs/dialog/delpost.jsp?boardid="+B+"&articleid="+A)},addBlackList:function(A,B){this.showDialog("加黑名单","/bbs/dialog/addblacklist.jsp?boardid="+A+"&username="+B)},addBread:function(A,B){this.showDialog("添加包子","/bbs/dialog/addBread.jsp?boardid="+A+"&username="+B)},chargePost:function(D,C,A,B){this.showDialog("投诉帖子","/bbs/dialog/chargepost.jsp?boardid="+D+"&threadid="+C+"articleid="+A+"&floor="+B)},chargePost_new:function(D,C,A,B){this.showDialog("投诉帖子","/bbs/dialog/chargepost.jsp?boardid="+D+"&threadid="+C+"&articleid="+A+"&floor="+B)},copyThread:function(B,A){this.showDialog("复制主贴","/bbs/dialog/copythread.jsp?boardid="+B+"&threadid="+A);Dialog.setWidth(550)},setAdminCommentTypes:function(C,A,B){this.showDialog("设置优点帖","/bbs/dialog/setAdminCommentTypes.jsp?boardid="+C+"&articleid="+A+"&types="+B)},setAskGoodAnswer:function(B,A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }if(!confirm("设置后不能再修改，是否确认设为最佳答案?")){return }Dwr.setAskGoodAnswer(B,A,function(C){alert(C);document.location.replace(document.location.href+"?a1")})},setAskPushAnswer:function(B,A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }if(!confirm("设置后不能再修改，是否确认设为推荐答案?")){return }Dwr.setAskPushAnswer(B,A,function(C){alert(C);document.location.replace(document.location.href)})}};var BbsAdminButton={init:"",articleid:0,show:function(A){this.articleid=A;var B=$("admin_"+A);B.style.display="block";B.onmouseout=BbsAdminButton.closeOut;B.onmouseover=BbsAdminButton.closeOver},curShow:null,closeOut:function(){this.curShow=setTimeout("BbsAdminButton.close()",100)},closeOver:function(){clearTimeout(this.curShow)},close:function(){var A=$("admin_"+this.articleid);A.style.display="none"}};var Nav={init:function(){if(document.body.offsetWidth<800){Nav.close()}else{if(BbsCookie.getCookie("shownav")=="false"){Nav.close()}}},close:function(){var A=document.getElementById("switchPoint");A.alt="展开左侧导航栏";A.src="/bbs/images/nav_middle_show.gif";document.getElementById("frmTitle").style.display="none";BbsCookie.setCookie("shownav","false",0)},open:function(){var A=document.getElementById("switchPoint");A.alt="收起左侧导航栏";A.src="/bbs/images/nav_middle_hide.gif";document.getElementById("frmTitle").style.display="";BbsCookie.setCookie("shownav","true",0)},isOpen:function(){var A=document.getElementById("switchPoint");return(A.alt=="收起左侧导航栏")},switchSysBar:function(){if(this.isOpen()){this.close()}else{this.open()}},show:function(){BbsCookie.setCookie("nav_show","y",-1)},hide:function(){BbsCookie.setCookie("nav_show","n",-1)},isHidden:function(){return(("n"==BbsCookie.getCookie("nav_show")))}};var BbsPlugin={init:""};var BbsTab={init:"",showLeftTab:function(A,B){$(A).style.display="block";$(A+"_title").addClassName("c1");$(A+"_title").addClassName("on");$(B).style.display="none";$(B+"_title").removeClassName("c2");$(B+"_title").removeClassName("on")},showRightTab:function(A,B){$(A).style.display="none";$(A+"_title").removeClassName("c1");$(A+"_title").removeClassName("on");$(B).style.display="block";$(B+"_title").addClassName("c2");$(B+"_title").addClassName("on")}};var MyXml={init:"",getValue:function(B,A){return B.getElementsByTagName(A)[0].firstChild.data}};var BbsBoard={init:"",addMyFavorite:function(A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }Dwr.addMyFavorite(A,function(B){var C=$("myCollection");if(C!=null){BbsLeft.loadMyFavorite();C.style.display="block"}alert(B)})},addMyFavorite_Yiba:function(A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }Dwr.addMyFavorite_Yiba(A,function(B){var C=$("myCollection");if(C!=null){BbsLeft.loadMyFavorite();C.style.display="block"}alert(B)})},deleteMyFavorite:function(A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }if(!confirm("是否确认删除该版面？")){return }Dwr.deleteMyFavorite(A,function(B){var C=$("myCollection_"+A);if(C!=null){C.style.display="none"}})},deleteMyFavorite_Yiba:function(A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }if(!confirm("是否确认删除该版面？")){return }Dwr.deleteMyFavorite_Yiba(A,function(B){var C=$("myCollection_"+A);if(C!=null){C.style.display="none"}})}};var BbsXml={init:"",load:function(B,D,C){var A={method:"get",parameters:D,onComplete:C};new Ajax.Request(B,A)},getNodeValue:function(B,A){return B.getElementsByTagName(A)[0].firstChild.data}};var YibaLogin={init:function(){},getForm:function(A){return document.forms[A]},dopost:function(A){var C=this.getForm(A);if(C.username.value==""){alert("请输入您的用户名.");C.username.focus();return false}if(C.password.value==""){alert("请输入密码.");C.password.focus();return false}Userinfo.removeUserinfo();var B=C.url.value;Bbs.loginPassport(C.username.value,C.password.value,Bbs.loginCallback);return false},dopost_return:function(A){var C=this.getForm(A);if(C.username.value==""){alert("请输入您的用户名");C.username.focus();return false}if(C.password.value==""){alert("请输入您的密码");C.password.focus();return false}Userinfo.removeUserinfo();var B=C.url.value;Bbs.loginPassport(C.username.value,C.password.value,Bbs.loginCallback);return true}};String.prototype.isDigit=function(){var A=/^([0-9])+$/;if(A.exec(this)){return true}return false};function insertContent(A){Editor.insertContent(A)}function quitOlympics(B,A,C){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true)}else{if(C!=BbsCookie.getPassport()){alert("该帖子不是您发表的，您无权操作.");return }if(confirm("是否确认退出奥运加油团？")){Dwr.quitOlympics(B,A,C,function(D){$("olympics_"+A).style.display="none";alert(D)})}}}function joinGoldmedal(C,A,B){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }Dwr.joinGoldmedal(C,A,B,function(D){if(D!=null&&D!=""){BbsAdmin.showDialog("传递爱","/bbs/dialog/goldmedal.jsp?data="+D);Dialog.setWidth(450)}})}function joinInGoldmedal(B,A){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }Dwr.joinGoldmedal(B,A,"",function(C){if(C!=null&&C!=""){BbsAdmin.showDialog("传递爱","/bbs/dialog/goldmedal.jsp?data="+C);Dialog.setWidth(450)}})}function joinChinaxinSpeciel(C,A,B){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }document.getElementById("spreed_btn").style.display="none";Dwr.joinChinaxin(C,A,B,function(D){if(D!=null&&D!=""){BbsAdmin.showDialog("中国心","/bbs/dialog/chinaxin.jsp?data="+escape(D));Dialog.setWidth(502);document.getElementById("spreed_btn").style.display="block";document.getElementById("draghead").style.display="none"}})}function joinChinaxin(C,A,B){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }Dwr.joinChinaxin(C,A,B,function(D){if(D!=null&&D!=""){BbsAdmin.showDialog("中国心","/bbs/dialog/chinaxin.jsp?data="+escape(D));Dialog.setWidth(502);document.getElementById("draghead").style.display="none"}})}function quitLibang(B,A,C){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true)}else{if(C!=BbsCookie.getPassport()){alert("该帖子不是您发表的，您无权操作.");return }if(confirm("是否确认退出立邦为爱上色活动？")){Dwr.quitLibang(B,A,C,function(D){$("libang_"+A).style.display="none";alert(D)})}}}var Upload={insertContent:function(A){if(Editor.getForm().content.value=="本论坛面向公众开放，请广大会员注意文明发帖，展现玫琳凯人‘美丽多面体’的职业形象。"){Editor.getForm().content.value=""}Editor.insertContent("\n[img]"+A+"[/img]\n",true)},insertAttachment:function(A){if(Editor.getForm().content.value=="本论坛面向公众开放，请广大会员注意文明发帖，展现玫琳凯人‘美丽多面体’的职业形象。"){Editor.getForm().content.value=""}Editor.insertContent("\n[plugin:attachment]"+A+"[/plugin:attachment]\n",true);Dialog.close()}};var Version={init:"",check:function(){try{if(typeof (js_version)=="string"){if(js_version!=all_js_version){this.autoReload()}}}catch(A){}},autoReload:function(){var A=document.createElement("FRAME");A.src="http://bbs.163.com/bbs/other/reload_js.jsp";if(document.frames){document.body.insertAdjacentElement("BeforeBegin",A)}else{document.body.appendChild(A)}},checkLastReply:function(E,C,B,I,D,G){if(1==1){return }var H=document.location.host;if(!(H=="test.bbs.163.com"||H=="bbs.lady.163.com"||H=="bbs2.lady.163.com"||H=="bbs.news.163.com"||H=="club.auto.163.com")){return }var A="http://new.fund8.money.163.com/bbs/check_lastreply.jsp?boardid="+global_boardid;A+="&threadid="+E;A+="&pageid="+C;A+="&start="+B;A+="&size="+I;A+="&lastreply="+D;A+="&lastFloor="+G;var F=new Image();F.src=A;DwrAlarm.checkLastReply(global_boardid,E,D,function(J){})}};var BbsBoardAdmin={init:"",load:function(){if(this.getMode()=="admin"){this.showCheckBox();return }},getList:function(){var B=$("articleRows").getElementsByTagName("input");if(B==null||typeof (B)=="undefined"||B.length==0){return null}else{var C=[];for(var A=0;A<B.length;A++){if(B[A].type=="checkbox"&&B[A].className=="admin"){C.push(Element.extend(B[A]))}}if(C.length==0){return null}return C}},checkMaster:function(){if(!BbsCookie.isLogined()){Bbs.showLoginDialog();return }if(this.getMode()=="user"){this.showCheckBox();return }else{if(this.getMode()=="admin"){this.hideCheckBox();return }else{if(this.isMaster()){this.showCheckBox()}else{alert("您“"+BbsCookie.getPassport()+"”不是版面“"+global_boardid+"”的版主，不能使用管理模式.");return }}}},isMaster:function(){var A=false;DWREngine.setAsync(false);DwrBoardAdmin.isBoardAdmin(global_boardid,function(B){A=B});DWREngine.setAsync(true);return A},setMode:function(A){var B="y";if(!A){B="n"}BbsCookie.setCookie("admin_mode",B,0)},getMode:function(){var A=BbsCookie.getCookie("admin_mode");if(A=="y"){return"admin"}else{if(A=="n"){return"normal"}else{return""}}},delCookie:function(){BbsCookie.setCookie("admin_mode","",0)},showCheckBox:function(){var B=this.getList();if(B!=null){for(var A=0;A<B.length;A++){B[A].style.display=""}}var C=$("boardadmin");C.style.display="";C.innerHTML="正常模式";C.href="javascript:BbsBoardAdmin.hideCheckBox()";this.showAdminButton()},hideCheckBox:function(){var B=this.getList();if(B!=null){for(var A=0;A<B.length;A++){B[A].style.display="none"}}var C=$("boardadmin");C.style.display="";C.innerHTML="批量删除";C.href="javascript:BbsBoardAdmin.showCheckBox()";this.hideAdminButton()},showAdminButton:function(){var C=document.getElementById("adminButton");var B=document.getElementById("adminButton_top");var A='<div style="text-align:left">';A+='<input  type="button" onclick="javascript:BbsBoardAdmin.delArticles();" value="删除"/>';A+='<input type="button" onclick="javascript:BbsBoardAdmin.selectAll();" value="全选" />';A+='<input type="button" onclick="javascript:BbsBoardAdmin.reverse();" value="反向选择" />';A+="</div>";C.innerHTML=A;B.innerHTML=A;C.style.display="";B.style.display="";this.setMode(true)},hideAdminButton:function(){var B=document.getElementById("adminButton");var A=document.getElementById("adminButton_top");B.style.display="none";A.style.display="none";this.setMode(false)},selectAll:function(){var A=this.getList();for(var B=0;B<A.length;B++){A[B].checked=true}},reverse:function(){var A=this.getList();for(var B=0;B<A.length;B++){A[B].checked=!A[B].checked}},delArticles:function(){if(!window.confirm("是否确认删除")){return false}var D=new Array();var C=this.getList();if(C==null){alert("当前列表没有帖子");return }var A=0;for(var B=0;B<C.length;B++){if(C[B].className=="admin"&&C[B].checked){D[A]=C[B].value;A++}}if(D==null||D.length==0){alert("您没有选中要删除的帖子.");return }DwrBoardAdmin.delArticle(D,function(H){var G=BbsBoardAdmin.getList();var E=H.split(", ");for(var F=0;F<E.length;F++){if(E[F]!=null&&E[F].length>0){BbsBoardAdmin.displayArticle(G,E[F])}}G=BbsBoardAdmin.getList();if(G==null){window.location.reload()}})},displayArticle:function(C,A){for(var B=0;B<C.length;B++){if(C[B].value.indexOf("/"+A)>0){var E=C[B].parentNode.parentNode;try{E.style.display="none";E.outerHTML=""}catch(D){E.innerHTML=""}}}}};var ChangeSelect={init:"",load:function(A,C,B,D){new Ajax.Request(C,{method:"GET",onComplete:function(J){var K=J.responseXML;if(K==null){return }var F=K.getElementsByTagName("row");DWRUtil.removeAllOptions(A);var M=D!=null&&typeof (D)!="undefined";if(M){try{A.add(D)}catch(L){A.appendChild(D)}}var I=0;for(i=0;i<F.length;i++){var H=F[i];var G=MyXml.getValue(H,"id");var E=MyXml.getValue(H,"name");try{A.add(new Option(E,G))}catch(L){A.appendChild(new Option(E,G))}if(B==G){if(M){I=i+1}else{I=i}}}A.selectedIndex=I}})}};var Drag={obj:null,init:function(A,B){A.onmousedown=Drag.start;A.root=B;if(isNaN(parseInt(A.root.style.left))){A.root.style.left="0px"}if(isNaN(parseInt(A.root.style.top))){A.root.style.top="0px"}A.root.onDragStart=new Function();A.root.onDragEnd=new Function();A.root.onDrag=new Function()},start:function(B){var A=Drag.obj=this;B=Drag.fixE(B);var D=parseInt(A.root.style.top);var C=parseInt(A.root.style.left);A.root.onDragStart(C,D,B.clientX,B.clientY);A.lastMouseX=B.clientX;A.lastMouseY=B.clientY;document.onmousemove=Drag.drag;document.onmouseup=Drag.end;return false},drag:function(B){B=Drag.fixE(B);var A=Drag.obj;var H=B.clientY;var G=B.clientX;var F=parseInt(A.root.style.top);var E=parseInt(A.root.style.left);var C,D;C=E+G-A.lastMouseX;D=F+H-A.lastMouseY;A.root.style.left=C+"px";A.root.style.top=D+"px";A.lastMouseX=G;A.lastMouseY=H;A.root.onDrag(C,D,B.clientX,B.clientY);return false},end:function(){document.onmousemove=null;document.onmouseup=null;Drag.obj.root.onDragEnd(parseInt(Drag.obj.root.style.left),parseInt(Drag.obj.root.style.top));Drag.obj=null},fixE:function(A){if(typeof A=="undefined"){A=window.event}if(typeof A.layerX=="undefined"){A.layerX=A.offsetX}if(typeof A.layerY=="undefined"){A.layerY=A.offsetY}return A}};Object.printAll=function(B){var C="";var A=0;for(dd in B){C+=dd+"  ";if((A+1)%5==0){C+="\n"}A++}alert(C)};var Dialog={init:"",dialogBox:null,defWidth:400,width:0,height:400,basePath:"",setBasePath:function(A){this.basePath=A},parseUrl:function(A){if(this.basePath==""){return A}if(A.substring(0,7)=="http://"){return A}var C;if(this.basePath.substring(this.basePath.length-1)=="/"){C=this.basePath.substring(0,this.basePath.length-1)}else{C=this.basePath}var B=A.substring(0);if("/"==B){A=C+A}else{A=C+"/"+A}return A},show:function(D,B,C,A){if(this.dialogBox==null){this.create()}this.setWidth(this.defWidth);this.dialogBox.style.display="block";this.setTitle(D);this.loading=setTimeout("Dialog.setLoading()",200);Drag.init(document.getElementById("draghead"),this.dialogBox);this.dialogBox.onDragEnd=function(E,F){Dialog.dialogBox.ox=E-Dialog.getRange().left;Dialog.dialogBox.oy=F-Dialog.getRange().top};this.center();B=this.parseUrl(B);this.loadContent(B,C,A)},setWidth:function(A){if(A!=this.width){this.width=A;this.dialogBox.style.width=A+"px";this.center()}},setHeight:function(A){if(A!=this.height){this.height=A}},loading:null,setLoading:function(){this.setContent("数据加载中...")},clearLoading:function(){if(this.loading!=null){clearTimeout(this.loading);this.loading=null}},loadContent:function(B,C,A){var D="?"+(new Date().getTime());new Ajax.Request(B,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(E){Dialog.clearLoading();$("dialogBox_content").innerHTML=(E.responseText);if(C){Dialog.loadCss(B+".css")}if(A){Dialog.loadJs(B+".js")}}})},setContent:function(A){document.getElementById("dialogBox_content").innerHTML="<div class='dialogBox_Content'>"+A+"</div>"},close:function(){if(this.dialogBox!=null){this.dialogBox.style.display="none"}},setTitle:function(A){document.getElementById("dialogBox_title").innerHTML=A},create:function(){this.loadCss("http://bbs.163.com/bbs/dialog/dialog.css");var A=document.createElement("DIV");A.id="dialogBox";A.className="dialogBoxBg";var B='<div class="dialogBox" style="cursor:pointer"><div id="draghead" class="title"><h2 id="dialogBox_title"></h2><span><a id="dialog_close_btn" href="javascript:Dialog.close()" target="_self"><img src="http://bbs.163.com/bbs/dialog/login01_div.gif" style="cursor:pointer" height="18" width="49" border="0" /></a></span></div><div class="content" id="dialogBox_content"></div></div>';A.innerHTML=B;document.body.appendChild(A);this.dialogBox=document.getElementById("dialogBox");this.center();this.addScrollEvent(Dialog.onBodyScroll)},loadCss:function(A){var B=document.getElementsByTagName("HEAD").item(0);var C=document.createElement("link");C.href=A;C.rel="stylesheet";C.type="text/css";B.appendChild(C)},loadJs:function(B){var A=document.getElementById("js1");if(A==null){A=document.createElement("script")}A.id="js1";A.src=B;if(document.frames){document.body.insertAdjacentElement("BeforeBegin",A)}else{document.body.appendChild(A)}},onBodyScroll:function(){var A=Dialog.getRange();var D=(A.top+Dialog.dialogBox.oy);var C=(A.left+Dialog.dialogBox.ox);if(D<5){D=5}if(C<5){C=5}Dialog.dialogBox.style.top=D+"px";Dialog.dialogBox.style.left=C+"px";if(typeof (Passport)!="undefined"&&Passport!=null){var B=document.getElementById("passportusernamelist");if(B!=null&&typeof (B)=="object"){Passport.resizeFunc()}}},center:function(){var B=Dialog.getRange();var A=this.getPosition();var D=(B.width-A.width)/2;var C=(B.height-A.height)/2;this.dialogBox.ox=D;this.dialogBox.oy=C;if(B.left>D){D=B.left+D}if(B.top>C){C=B.top+C}this.dialogBox.style.left=D+"px";this.dialogBox.style.top=C+"px"},center_bak:function(){var A=Dialog.getRange();var C=(A.width-this.width)/2;var B=(A.height-this.height)/2;this.dialogBox.ox=C;this.dialogBox.oy=B;if(A.left>C){C=A.left+C}if(A.top>B){B=A.top+B}this.dialogBox.style.left=C+"px";this.dialogBox.style.top=B+"px"},move:function(B,A){this.dialogBox.ox=B;this.dialogBox.oy=A;this.dialogBox.style.left=B+"px";this.dialogBox.style.top=A+"px"},isCreated:function(){return(this.dialogBox==null)},getPosition:function(){if(this.dialogBox==null){return{top:0,left:0,height:this.height,width:this.width}}var D=this.dialogBox.offsetTop;var C=this.dialogBox.offsetLeft;var B=this.dialogBox.offsetWidth;var A=this.dialogBox.offsetHeight;if(A<this.height){A=this.height}return{top:D,left:C,height:A,width:B}},getRange:function(){var D=document.documentElement.scrollTop;var C=document.documentElement.scrollLeft;var A=document.documentElement.clientHeight;var B=document.documentElement.clientWidth;if(D==0){D=document.body.scrollTop}if(C==0){C=document.body.scrollLeft}if(A==0){A=document.body.clientHeight}if(B==0){B=document.body.clientWidth}return{top:D,left:C,height:A,width:B}},addScrollEvent:function(A){var B=window.onscroll;if(typeof window.onscroll!="function"){window.onscroll=A}else{window.onscroll=function(){B();A()}}},addResizeEvent:function(B){var A=window.onresize;if(typeof window.onresize!="function"){window.onresize=B}else{window.onresize=function(){A();B()}}}};var Request={init:"",getParameter:function(B){var A=document.location.href;var G=A.indexOf("?")+1;if(G==0){return""}var E="";var F=A.substring(G);var D=F.split("&");for(var C=0;C<D.length;C++){if(B==this.getParameterName(D[C])){E=this.getParameterValue(D[C])}}return E},getParameterName:function(A){var B=A.indexOf("=");if(B==-1){return A}return A.substring(0,B)},getParameterValue:function(A){var B=A.indexOf("=");if(B==-1){return""}return A.substring(B+1)}};var BoardUtil={init:"",objId:"selectBoardid",dbname:"",loadBoardList:function(C,A,B){this.dbname=C;Dwr.loadBoardList(C,"",function(H){DWRUtil.removeAllOptions(BoardUtil.objId);var G=$(BoardUtil.objId);for(var J in H){var I=H[J];var F=I.hasChild;var D=I.name;var E=new Option(D,J);E.hasChild=F;G.options[G.options.length]=E}if(B){BoardUtil.selectDefault()}})},hasChild:function(A){var D=$(BoardUtil.objId);var B=D.options[A];var C=B.hasChild;return(C=="true")},selectDefault:function(){var A=$(BoardUtil.objId);var B="";if(A.options.length>0){B=A.options[0].value;this.changeBoard(B,0)}$("destBoardid").value=B},changeBoard:function(D,A){$("destBoardid").value=D;var C=BoardUtil.objId+"Child";var B=BoardUtil.hasChild(A);if(B){if(this.dbname==""){this.dbname=$("destDbname").value}Dwr.loadBoardList(this.dbname,D,function(G){DWRUtil.removeAllOptions(C);var F=$(C);var E=new Option("默认",D);E.hasChild=B;F.options[F.options.length]=E;DWRUtil.addOptions(C,G,"boardid","name")});$(C).style.display=""}else{$(C).style.display="none"}}};var BbsSearch={init:"",showMenu:function(){var A=$("searchMenu");if(A.style.display=="none"){A.style.display="block"}else{A.style.display="none"}},getForm:function(){return document.forms.search},inner:function(){var A=this.getForm();A.target="_blank"},global:function(){var A=this.getForm();A.target="_blank";$("searchRan").value="bbs";$("boardid").value=""}};BbsBoardAdmin.showAdminButton=function(){var B=document.getElementById("adminButton_top");var C=document.getElementById("adminButton");var A='<input type="button" onclick="javascript:BbsBoardAdmin.delArticles();" value="删除" />';A+='<input type="button" onclick="javascript:BbsBoardAdmin.selectAll();" value="全选" />';A+='<input type="button" onclick="javascript:BbsBoardAdmin.reverse();" value="反向选择" />';B.innerHTML=A;B.style.display="";C.innerHTML=A;C.style.display="";this.setMode(true)};BbsBoardAdmin.hideAdminButton=function(){var A=document.getElementById("adminButton_top");var B=document.getElementById("adminButton");A.style.display="none";B.style.display="none";this.setMode(false)};BbsUtil.showLoginInfo=function(){var F=document.getElementById("myLoginButton");var D=document.getElementById("myLink");if(D==null||D=="undefine"){return this.showLoginButton()}var C="";var B="";if(BbsCookie.isLogined()){var H=BbsCookie.getPassport();var G=BbsCookie.getCookie("admin_mode");if(typeof (noNicknameInfo)=="undefined"){C+=('<a class="cRed" href="http://bbs.163.com/'+H+'" target="_blank" >'+Userinfo.getNickname()+"</a>")}var A=Userinfo.getMessageCount();if(A<0){A=0}C+=' | <a href="http://bbs.163.com/sns/msg_sns.jsp" target="_blank">短消息</a>(<a href="http://bbs.163.com/sns/msg_sns.jsp" target="_blank" style="color:red">'+A+'</a>) | <a href="http://help.3g.163.com/bbs/" target="_blank">手机版</a> ';C+=' | <span onclick="BbsList.toggle(\'myLink\')"><a class="dArrow">我的信息</a></span>';if(filename=="list"){C+=' | <a onclick="BbsList.toggle(\'myLink2\')"  style="cursor:pointer"  class="dArrow">管理模式</a>'}else{C+='<span id="boardadmin_span"> | <a href="http://bbs.news.163.com/list/tyro.html" id="boardadmin">论坛帮助</a></span>'}C+=' | <a href="javascript:Bbs.logout()" target="_self">退出</a>';B+='<h5><a href="http://bbs.163.com/'+H+'" onclick="BbsList.toggle(\'myLink\')" target="_blank">我的信息</a></h5>';B+='<h5><a href="http://bbs.163.com/bbs/sns/my_post_list1.jsp?username='+H+"&boardid="+global_boardid+'" onclick="BbsList.toggle(\'myLink\')" target="_blank">本版发帖</a></h5>';B+='<h5><a href="http://bbs.163.com/bbs/sns/my_reply_list1.jsp?username='+H+"&boardid="+global_boardid+'" onclick="BbsList.toggle(\'myLink\')" target="_blank">本版回复</a></h5>';D.innerHTML=B}else{C+='[<a href="javascript:Bbs.showLoginDialog(BbsUtil.reloadPage)" target="_self" class="aLogin">登录</a>] <a href="http://bbs.news.163.com/list/tyro.html" target="_blank">帮助</a> <a href="http://help.3g.163.com/bbs/" target="_blank">手机版</a>'}F.innerHTML=C;if(filename=="list"){try{BbsBoardAdmin.load()}catch(E){}}};var BbsList={init:function(){Userinfo.loadUserinfo()},toggle:function(A){obj=document.getElementById(A);obj.style.display=(obj.style.display=="")?"none":""},changeIframe:function(){BbsList.toggle("leftBar");var B=document.getElementById("changeImg");var A=document.getElementById("mainArea");B.src=(B.src.indexOf("left")!=-1)?B.src.replace("left","right"):B.src.replace("right","left");A.style.marginLeft=(A.style.marginLeft=="0px")?"145px":"0px"},onTabChange:function(D,E,A,C){var B=1;while(B<=C){if(B!=A){href_obj=document.getElementById(D+B);if(href_obj!=null){href_obj.className=""}div_obj=document.getElementById(E+B);if(div_obj!=null){div_obj.style.display="none"}}B=B+1}href_obj=document.getElementById(D+A);if(href_obj!=null){href_obj.className="active"}div_obj=document.getElementById(E+A);if(div_obj!=null){div_obj.style.display="block"}}};var BbsSimple={init:function(){var A=document.location.href;if(A.indexOf(".html")==-1){return }if(A.indexOf("/simple/")>0){try{BbsList.changeIframe()}catch(B){}this.hideHeader();this.hideFooter();this.hideFloatLayer();return }else{if(A.indexOf("/noheader/")>0){this.hideHeader();return }else{if(A.indexOf("/nofooter/")>0){this.hideFooter();return }else{if(A.indexOf("/nofloatlayer/")>0){this.hideFloatLayer();return }}}}},hideHeader:function(){var A=$("boardHeader");if(A!=null){A.style.display="none"}},hideFooter:function(){var A=$("footer");if(A!=null){A.style.display="none"}},hideFloatLayer:function(){var A=$("floatLayer");if(A!=null){A.style.display="none"}}};var BbsLeft={init:function(){var B=Bbs.getChannel();var A=B;var C=null;if(B=="news"){if(global_boardid.indexOf("local")==0){A="local"}}if(B=="2010"){A="sports"}if(B=="service"){this.show_channel("service",C)}else{this.show_channel("service",C);this.show_channel(A,C)}},show_channel:function(C,E){if("myCollection"==C){return this.showMyFavorite()}if($(C)==null){return }if(pageChannel!="dream"){if($(C).style.display=="none"&&$("out_"+C).previous().readAttribute("tindex")!=2){this.move(C)}}var D=$(C);var B=$("ch_"+C);if(D==null&&typeof (D)=="undefined"){return }if(D.style.display=="block"){D.style.display="none";B.className=""}else{if(D.style.display=="none"&&D.innerHTML!=""){D.style.display="block";B.className="active"}else{var A="/htmlfile/left/"+C+"_child.htm";D.style.display="block";D.innerHTML="<h4>数据加载中...</h4>";new Ajax.Request(A,{method:"get",requestHeaders:["If-Modified-Since","0"],onComplete:function(G){var F=(G.responseText);D.innerHTML=F;B.className="active";if(E!=null&&(typeof (E)=="function"||typeof (E)=="object")){E()}}})}}},move:function(B){var F=$("out_"+B);var A=F.readAttribute("tindex");var H='<div class="tselector" tindex="'+A+'" id="out_'+B+'">'+F.innerHTML+"</div>";var G=$("out_myset");if(A<=2){return }if(A>2){var I=G.next();for(var C=0;C<I.childNodes.length;C++){if(I.childNodes[C].nodeType==1){if(I.childNodes[C].nodeName=="H3"){I.childNodes[C].className=""}if(I.childNodes[C].nodeName=="DIV"){I.childNodes[C].style.display="none"}}}var J=I.readAttribute("tindex");if(J!=3){var D='<div class="tselector" tindex="'+J+'" id="'+I.readAttribute("id")+'">'+I.innerHTML+"</div>";I.remove();var K=$("leftMenu").getElementsByClassName("tselector");for(var C=0;C<K.length;C++){var E=K[C].readAttribute("tindex");if(E==J-1){new Insertion.After(K[E],D);break}}}F.remove();new Insertion.After(G,H);document.documentElement.scrollTop=0}},showDiv:function(C){var B=$(C);if(B==null){}var D=B.style.display;var A=$("img_"+C);if(D=="none"){B.style.display="block";if(A!=null&&typeof (A)!="undefined"){A.src="/bbs/img/b.gif"}}if(D=="block"){B.style.display="none";if(A!=null&&typeof (A)!="undefined"){A.src="/bbs/img/a.gif"}}},showMyFavorite:function(){if(!BbsCookie.isLogined()){Bbs.showLoginDialog(true);return }var A=$("myCollection");var B=$("ch_myCollection");if(A.style.display=="none"){A.style.display="block";B.className="active";BbsLeft.loadMyFavorite()}else{A.style.display="none";B.className=""}},loadMyFavorite:function(){var A="/bbs/my_favorite.inc.jsp";new Ajax.Request(A,{onComplete:function(C){var B=(C.responseText);if(C.status==200){$("myCollection").innerHTML=B}else{alert("请求出错.")}}})}};var channel_db_map=[["bbs.news.163.com","news"],["bbs2.news.163.com","news"],["bbs3.news.163.com","news"],["bbs4.news.163.com","news"],["bbs5.news.163.com","news"],["bbs6.news.163.com","news"],["bbs7.news.163.com","news"],["bbs8.news.163.com","news"],["bbs9.news.163.com","news"],["bbs.lady.163.com","lady"],["bbs2.lady.163.com","lady"],["bbs.talk.163.com","talk"],["guba.money.163.com","stock"],["fund8.money.163.com","stock"],["bbs.stock.163.com","stock"],["bbs.culture.163.com","culture"],["club.auto.163.com","auto"],["bbs.travel.163.com","travel"],["club.tech.163.com","mobile"],["bbs.tech.163.com","tech"],["digibbs.tech.163.com","digi"],["bbs.biz.163.com","biz"],["bbs.2008.163.com","2008"],["bbs.sports.163.com","sports"],["bbs2.sports.163.com","sports"],["bbs.education.163.com","education"],["bbs.ent.163.com","ent"],["bbs.bj.163.com","local"]];if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrQianMing==null){var DwrQianMing={}}DwrQianMing._path="/bbs/dwr";DwrQianMing.main=function(B,A){dwr.engine._execute(DwrQianMing._path,"DwrQianMing","main",B,A)};DwrQianMing.add=function(B,A){dwr.engine._execute(DwrQianMing._path,"DwrQianMing","add",B,false,A)};DwrQianMing.sayBad=function(B,A){dwr.engine._execute(DwrQianMing._path,"DwrQianMing","sayBad",B,false,A)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrSystemAdmin==null){var DwrSystemAdmin={}}DwrSystemAdmin._path="/bbs/dwr";DwrSystemAdmin.delBlackList=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delBlackList",C,A,false,B)};DwrSystemAdmin.delIpLimit=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delIpLimit",B,false,A)};DwrSystemAdmin.isEditor=function(A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isEditor",false,A)};DwrSystemAdmin.auditArticle=function(D,B,A,C){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","auditArticle",D,B,A,false,C)};DwrSystemAdmin.allAuditArticle=function(D,B,A,C){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","allAuditArticle",D,B,A,false,C)};DwrSystemAdmin.batchAuditArticle=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","batchAuditArticle",B,false,A)};DwrSystemAdmin.isSuperEditor=function(A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isSuperEditor",false,A)};DwrSystemAdmin.boardClose=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","boardClose",B,false,A)};DwrSystemAdmin.boardAudit=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","boardAudit",B,false,A)};DwrSystemAdmin.boardReplyAudit=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","boardReplyAudit",B,false,A)};DwrSystemAdmin.moveNav=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","moveNav",C,A,false,B)};DwrSystemAdmin.updateDirectory=function(D,B,A,C){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","updateDirectory",D,B,A,false,C)};DwrSystemAdmin.delDirectory=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delDirectory",C,A,false,B)};DwrSystemAdmin.addMaster=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","addMaster",C,A,false,B)};DwrSystemAdmin.delMaster=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delMaster",C,A,false,B)};DwrSystemAdmin.updateMaster=function(D,B,A,C){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","updateMaster",D,B,A,false,C)};DwrSystemAdmin.moveMaster=function(D,B,A,C){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","moveMaster",D,B,A,false,C)};DwrSystemAdmin.moveSide=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","moveSide",C,A,false,B)};DwrSystemAdmin.moveBoard=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","moveBoard",C,A,false,B)};DwrSystemAdmin.updateMasterHtml=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","updateMasterHtml",B,false,A)};DwrSystemAdmin.delSignBlack=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delSignBlack",C,A,false,B)};DwrSystemAdmin.changeGuestIp=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","changeGuestIp",B,false,A)};DwrSystemAdmin.postKeyword=function(G,E,D,C,B,A,F){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","postKeyword",G,E,D,C,B,A,false,F)};DwrSystemAdmin.delKeyword=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delKeyword",C,A,false,B)};DwrSystemAdmin.delPrivilegeUser=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delPrivilegeUser",B,false,A)};DwrSystemAdmin.postWebmasterPurview=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","postWebmasterPurview",C,A,false,B)};DwrSystemAdmin.delWebmaster=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","delWebmaster",B,false,A)};DwrSystemAdmin.pageGenerator=function(E,C,B,A,D){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","pageGenerator",E,C,B,A,false,D)};DwrSystemAdmin.postSide=function(F,D,C,B,A,E){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","postSide",F,D,C,B,A,false,E)};DwrSystemAdmin.makeSide=function(A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","makeSide",false,A)};DwrSystemAdmin.checkForfendArticle=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","checkForfendArticle",C,A,false,B)};DwrSystemAdmin.isLegalBoard=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isLegalBoard",B,A)};DwrSystemAdmin.sendSysMessage=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","sendSysMessage",C,A,false,B)};DwrSystemAdmin.sendChannelMessage=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","sendChannelMessage",C,A,false,B)};DwrSystemAdmin.isGarbageByContent=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isGarbageByContent",C,A,false,B)};DwrSystemAdmin.isGarbage=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isGarbage",C,A,false,B)};DwrSystemAdmin.isMessageGarbage=function(C,A,B){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","isMessageGarbage",C,A,false,B)};DwrSystemAdmin.deleteGarbage=function(B,A){dwr.engine._execute(DwrSystemAdmin._path,"DwrSystemAdmin","deleteGarbage",B,false,A)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrBoardAdmin==null){var DwrBoardAdmin={}}DwrBoardAdmin._path="/bbs/dwr";DwrBoardAdmin.main=function(B,A){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","main",B,A)};DwrBoardAdmin.isBoardAdmin=function(B,A){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","isBoardAdmin",B,false,A)};DwrBoardAdmin.delArticle=function(B,A){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","delArticle",B,false,A)};DwrBoardAdmin.auditArticle=function(D,B,A,C){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","auditArticle",D,B,A,false,C)};DwrBoardAdmin.allAuditArticle=function(D,B,A,C){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","allAuditArticle",D,B,A,false,C)};DwrBoardAdmin.batchAuditArticle=function(B,A){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","batchAuditArticle",B,false,A)};DwrBoardAdmin.searchBoards=function(C,A,B){dwr.engine._execute(DwrBoardAdmin._path,"DwrBoardAdmin","searchBoards",C,A,false,B)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrAlarm==null){var DwrAlarm={}}DwrAlarm._path="/bbs/dwr";DwrAlarm.main=function(B,A){dwr.engine._execute(DwrAlarm._path,"DwrAlarm","main",B,A)};DwrAlarm.oldJsVersion=function(E,C,B,A,D){dwr.engine._execute(DwrAlarm._path,"DwrAlarm","oldJsVersion",E,C,B,A,false,D)};DwrAlarm.checkLastReply=function(H,F,E,D,C,B,A,G){dwr.engine._execute(DwrAlarm._path,"DwrAlarm","checkLastReply",H,F,E,D,C,B,A,false,G)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrPlugin==null){var DwrPlugin={}}DwrPlugin._path="/bbs/dwr";DwrPlugin.main=function(B,A){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","main",B,A)};DwrPlugin.saveHtml=function(E,C,B,A,D){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveHtml",E,C,B,A,false,D)};DwrPlugin.saveTravel=function(O,N,L,K,J,I,H,G,F,E,D,C,B,A,M){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveTravel",O,N,L,K,J,I,H,G,F,E,D,C,B,A,false,M)};DwrPlugin.saveXiangQin=function(M,L,J,I,H,G,F,E,D,C,B,A,K){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveXiangQin",M,L,J,I,H,G,F,E,D,C,B,A,false,K)};DwrPlugin.saveDaren=function(K,J,H,G,F,E,D,C,B,A,I){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveDaren",K,J,H,G,F,E,D,C,B,A,false,I)};DwrPlugin.saveItmm=function(I,H,F,E,D,C,B,A,G){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveItmm",I,H,F,E,D,C,B,A,false,G)};DwrPlugin.saveItmm2009=function(I,H,F,E,D,C,B,A,G){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveItmm2009",I,H,F,E,D,C,B,A,false,G)};DwrPlugin.saveStreet=function(I,H,F,E,D,C,B,A,G){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveStreet",I,H,F,E,D,C,B,A,false,G)};DwrPlugin.saveBaby=function(J,I,G,F,E,D,C,B,A,H){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveBaby",J,I,G,F,E,D,C,B,A,false,H)};DwrPlugin.saveBaby2=function(I,H,F,E,D,C,B,A,G){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveBaby2",I,H,F,E,D,C,B,A,false,G)};DwrPlugin.saveWage=function(L,K,I,H,G,F,E,D,C,B,A,J){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveWage",L,K,I,H,G,F,E,D,C,B,A,false,J)};DwrPlugin.saveTicket=function(O,N,L,K,J,I,H,G,F,E,D,C,B,A,M){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveTicket",O,N,L,K,J,I,H,G,F,E,D,C,B,A,false,M)};DwrPlugin.saveOlympics=function(J,I,G,F,E,D,C,B,A,H){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveOlympics",J,I,G,F,E,D,C,B,A,false,H)};DwrPlugin.saveChunyun=function(G,E,D,C,B,A,F){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveChunyun",G,E,D,C,B,A,false,F)};DwrPlugin.saveHire=function(N,M,K,J,I,H,G,F,E,D,C,B,A,L){dwr.engine._execute(DwrPlugin._path,"DwrPlugin","saveHire",N,M,K,J,I,H,G,F,E,D,C,B,A,false,L)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(DwrClub==null){var DwrClub={}}DwrClub._path="/bbs/dwr";DwrClub.getHeader=function(B,A){dwr.engine._execute(DwrClub._path,"DwrClub","getHeader",B,false,A)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}if(Dwr==null){var Dwr={}}Dwr._path="/bbs/dwr";Dwr.main=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","main",B,A)};Dwr.test=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","test",B,false,A)};Dwr.nodes=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","nodes",C,A,B)};Dwr.topThread=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","topThread",C,A,false,B)};Dwr.eliteThread=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","eliteThread",E,C,B,A,false,D)};Dwr.pushThread=function(F,D,C,B,A,E){dwr.engine._execute(Dwr._path,"Dwr","pushThread",F,D,C,B,A,false,E)};Dwr.copyThread=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","copyThread",E,C,B,A,false,D)};Dwr.lockThread=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","lockThread",C,A,false,B)};Dwr.rubbishThread=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","rubbishThread",C,A,false,B)};Dwr.delPost=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","delPost",C,A,false,B)};Dwr.setAdminCommentTypes=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","setAdminCommentTypes",D,B,A,false,C)};Dwr.addBlackList=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","addBlackList",E,C,B,A,false,D)};Dwr.addBread=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","addBread",E,C,B,A,false,D)};Dwr.blackUser=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","blackUser",E,C,B,A,false,D)};Dwr.delBlackUser=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","delBlackUser",D,B,A,false,C)};Dwr.addIpLimit=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","addIpLimit",E,C,B,A,false,D)};Dwr.allTopThread=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","allTopThread",D,B,A,false,C)};Dwr.chargePost=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","chargePost",D,B,A,false,C)};Dwr.chargePost_new=function(N,M,K,J,I,H,G,F,E,D,C,B,A,L){dwr.engine._execute(Dwr._path,"Dwr","chargePost_new",N,M,K,J,I,H,G,F,E,D,C,B,A,false,L)};Dwr.loginPassport=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","loginPassport",C,A,false,false,B)};Dwr.lostPost=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","lostPost",B,false,A)};Dwr.delMessage=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","delMessage",B,false,A)};Dwr.delMessages=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","delMessages",B,false,A)};Dwr.delSentMessage=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","delSentMessage",B,false,A)};Dwr.delSentMessages=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","delSentMessages",B,false,A)};Dwr.delBlackList=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","delBlackList",B,false,A)};Dwr.sendMessage=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","sendMessage",C,A,false,B)};Dwr.addMyBlackList=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","addMyBlackList",C,A,false,B)};Dwr.getQuoteReply=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","getQuoteReply",C,A,B)};Dwr.sayGood=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","sayGood",C,A,false,B)};Dwr.sayBad=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","sayBad",C,A,false,B)};Dwr.editReply=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","editReply",D,B,A,false,C)};Dwr.updateVote=function(G,E,D,C,B,A,F){dwr.engine._execute(Dwr._path,"Dwr","updateVote",G,E,D,C,B,A,false,F)};Dwr.vote=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","vote",E,C,B,A,false,D)};Dwr.getBoardName=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getBoardName",B,false,A)};Dwr.getBoardNames=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getBoardNames",B,false,A)};Dwr.loadBoardList=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","loadBoardList",C,A,false,B)};Dwr.loadBoardListByKeyword=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","loadBoardListByKeyword",D,B,A,false,C)};Dwr.getChildBoards=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getChildBoards",B,false,A)};Dwr.getChildBoardsByDbname=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","getChildBoardsByDbname",C,A,false,B)};Dwr.getNickname=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getNickname",B,A)};Dwr.updateNickname=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","updateNickname",C,A,false,B)};Dwr.updateUserinfo=function(H,F,E,D,C,B,A,G){dwr.engine._execute(Dwr._path,"Dwr","updateUserinfo",H,F,E,D,C,B,A,false,G)};Dwr.isWantVerify=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","isWantVerify",B,false,A)};Dwr.getAutoHeader=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getAutoHeader",B,false,A)};Dwr.delIpLimit=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","delIpLimit",C,A,false,B)};Dwr.getReplyBody=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","getReplyBody",C,A,B)};Dwr.quitOlympics=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","quitOlympics",D,B,A,false,C)};Dwr.quitLibang=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","quitLibang",D,B,A,false,C)};Dwr.joinGoldmedal=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","joinGoldmedal",D,B,A,false,C)};Dwr.joinChinaxin=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","joinChinaxin",D,B,A,false,C)};Dwr.addMyFavorite=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","addMyFavorite",B,false,A)};Dwr.deleteMyFavorite=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","deleteMyFavorite",B,false,A)};Dwr.addMyFavorite_Yiba=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","addMyFavorite_Yiba",B,false,A)};Dwr.deleteMyFavorite_Yiba=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","deleteMyFavorite_Yiba",B,false,A)};Dwr.getOnlineStatus=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getOnlineStatus",B,false,A)};Dwr.copyToBlog=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","copyToBlog",C,A,false,B)};Dwr.setAskGoodAnswer=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","setAskGoodAnswer",C,A,false,B)};Dwr.setAskPushAnswer=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","setAskPushAnswer",C,A,false,B)};Dwr.getBoardUrlByBoardid=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","getBoardUrlByBoardid",C,A,false,B)};Dwr.getCityByProvince=function(B,A){dwr.engine._execute(Dwr._path,"Dwr","getCityByProvince",B,A)};Dwr.addGuide=function(F,D,C,B,A,E){dwr.engine._execute(Dwr._path,"Dwr","addGuide",F,D,C,B,A,false,E)};Dwr.deleteGuide=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","deleteGuide",C,A,false,B)};Dwr.addArticleLimit=function(D,B,A,C){dwr.engine._execute(Dwr._path,"Dwr","addArticleLimit",D,B,A,false,C)};Dwr.deleteArticleLimit=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","deleteArticleLimit",C,A,false,B)};Dwr.isLimitThread=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","isLimitThread",C,A,false,B)};Dwr.hasForfendKeyword=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","hasForfendKeyword",E,C,B,A,false,D)};Dwr.hasSubtleKeyword=function(E,C,B,A,D){dwr.engine._execute(Dwr._path,"Dwr","hasSubtleKeyword",E,C,B,A,false,D)};Dwr.addApplyMaster=function(G,E,D,C,B,A,F){dwr.engine._execute(Dwr._path,"Dwr","addApplyMaster",G,E,D,C,B,A,false,F)};Dwr.copyUrl=function(C,A,B){dwr.engine._execute(Dwr._path,"Dwr","copyUrl",C,A,false,B)};if(dwr==null){var dwr={}}if(dwr.engine==null){dwr.engine={}}if(DWREngine==null){var DWREngine=dwr.engine}dwr.engine.setErrorHandler=function(A){dwr.engine._errorHandler=A};dwr.engine.setWarningHandler=function(A){dwr.engine._warningHandler=A};dwr.engine.setTextHtmlHandler=function(A){dwr.engine._textHtmlHandler=A};dwr.engine.setTimeout=function(A){dwr.engine._timeout=A};dwr.engine.setPreHook=function(A){dwr.engine._preHook=A};dwr.engine.setPostHook=function(A){dwr.engine._postHook=A};dwr.engine.setHeaders=function(A){dwr.engine._headers=A};dwr.engine.setParameters=function(A){dwr.engine._parameters=A};dwr.engine.XMLHttpRequest=1;dwr.engine.IFrame=2;dwr.engine.ScriptTag=3;dwr.engine.setRpcType=function(A){if(A!=dwr.engine.XMLHttpRequest&&A!=dwr.engine.IFrame&&A!=dwr.engine.ScriptTag){dwr.engine._handleError(null,{name:"dwr.engine.invalidRpcType",message:"RpcType must be one of dwr.engine.XMLHttpRequest or dwr.engine.IFrame or dwr.engine.ScriptTag"});return }dwr.engine._rpcType=A};dwr.engine.setHttpMethod=function(A){if(A!="GET"&&A!="POST"){dwr.engine._handleError(null,{name:"dwr.engine.invalidHttpMethod",message:"Remoting method must be one of GET or POST"});return }dwr.engine._httpMethod=A};dwr.engine.setOrdered=function(A){dwr.engine._ordered=A};dwr.engine.setAsync=function(A){dwr.engine._async=A};dwr.engine.setActiveReverseAjax=function(A){if(A){if(dwr.engine._activeReverseAjax){return }dwr.engine._activeReverseAjax=true;dwr.engine._poll()}else{if(dwr.engine._activeReverseAjax&&dwr.engine._pollReq){dwr.engine._pollReq.abort()}dwr.engine._activeReverseAjax=false}};dwr.engine.defaultErrorHandler=function(B,A){dwr.engine._debug("Error: "+A.name+", "+A.message,true);if(B==null||B==""){alert("A server error has occured.")}else{if(B.indexOf("0x80040111")!=-1){dwr.engine._debug(B)}else{alert(B)}}};dwr.engine.defaultWarningHandler=function(B,A){dwr.engine._debug(B)};dwr.engine.beginBatch=function(){if(dwr.engine._batch){dwr.engine._handleError(null,{name:"dwr.engine.batchBegun",message:"Batch already begun"});return }dwr.engine._batch=dwr.engine._createBatch()};dwr.engine.endBatch=function(B){var A=dwr.engine._batch;if(A==null){dwr.engine._handleError(null,{name:"dwr.engine.batchNotBegun",message:"No batch in progress"});return }dwr.engine._batch=null;if(A.map.callCount==0){return }if(B){dwr.engine._mergeBatch(A,B)}if(dwr.engine._ordered&&dwr.engine._batchesLength!=0){dwr.engine._batchQueue[dwr.engine._batchQueue.length]=A}else{dwr.engine._sendData(A)}};dwr.engine.setPollMethod=function(A){dwr.engine.setPollType(A)};dwr.engine.setMethod=function(A){dwr.engine.setRpcType(A)};dwr.engine.setVerb=function(A){dwr.engine.setHttpMethod(A)};dwr.engine.setPollType=function(){dwr.engine._debug("Manually setting the Poll Type is not supported")};dwr.engine._origScriptSessionId="0C4E29754E2FF8D000B7C2270518D5EF";dwr.engine._sessionCookieName="JSESSIONID";dwr.engine._allowGetForSafariButMakeForgeryEasier="false";dwr.engine._scriptTagProtection="throw 'allowScriptTagRemoting is false.';";dwr.engine._defaultPath="/bbs/dwr";dwr.engine._pollWithXhr="false";dwr.engine._scriptSessionId=null;dwr.engine._getScriptSessionId=function(){if(dwr.engine._scriptSessionId==null){dwr.engine._scriptSessionId=dwr.engine._origScriptSessionId+Math.floor(Math.random()*1000)}return dwr.engine._scriptSessionId};dwr.engine._errorHandler=dwr.engine.defaultErrorHandler;dwr.engine._warningHandler=dwr.engine.defaultWarningHandler;dwr.engine._preHook=null;dwr.engine._postHook=null;dwr.engine._batches={};dwr.engine._batchesLength=0;dwr.engine._batchQueue=[];dwr.engine._rpcType=dwr.engine.XMLHttpRequest;dwr.engine._httpMethod="POST";dwr.engine._ordered=false;dwr.engine._async=true;dwr.engine._batch=null;dwr.engine._timeout=0;dwr.engine._DOMDocument=["Msxml2.DOMDocument.6.0","Msxml2.DOMDocument.5.0","Msxml2.DOMDocument.4.0","Msxml2.DOMDocument.3.0","MSXML2.DOMDocument","MSXML.DOMDocument","Microsoft.XMLDOM"];dwr.engine._XMLHTTP=["Msxml2.XMLHTTP.6.0","Msxml2.XMLHTTP.5.0","Msxml2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"];dwr.engine._activeReverseAjax=false;dwr.engine._outstandingIFrames=[];dwr.engine._pollReq=null;dwr.engine._pollCometInterval=200;dwr.engine._pollRetries=0;dwr.engine._maxPollRetries=0;dwr.engine._textHtmlHandler=null;dwr.engine._headers=null;dwr.engine._parameters=null;dwr.engine._postSeperator="\n";dwr.engine._defaultInterceptor=function(A){return A};dwr.engine._urlRewriteHandler=dwr.engine._defaultInterceptor;dwr.engine._contentRewriteHandler=dwr.engine._defaultInterceptor;dwr.engine._replyRewriteHandler=dwr.engine._defaultInterceptor;dwr.engine._nextBatchId=0;dwr.engine._propnames=["rpcType","httpMethod","async","timeout","errorHandler","warningHandler","textHtmlHandler"];dwr.engine._partialResponseNo=0;dwr.engine._partialResponseYes=1;dwr.engine._partialResponseFlush=2;dwr.engine._unloading=false;dwr.engine._execute=function(K,B,I,H){var E=false;if(dwr.engine._batch==null){dwr.engine.beginBatch();E=true}var D=dwr.engine._batch;var G=[];for(var C=0;C<arguments.length-3;C++){G[C]=arguments[C+3]}if(D.path==null){D.path=K}else{if(D.path!=K){dwr.engine._handleError(D,{name:"dwr.engine.multipleServlets",message:"Can't batch requests to multiple DWR Servlets."});return }}var A;var J=G[G.length-1];if(typeof J=="function"||J==null){A={callback:G.pop()}}else{A=G.pop()}dwr.engine._mergeBatch(D,A);D.handlers[D.map.callCount]={exceptionHandler:A.exceptionHandler,callback:A.callback};var F="c"+D.map.callCount+"-";D.map[F+"scriptName"]=B;D.map[F+"methodName"]=I;D.map[F+"id"]=D.map.callCount;for(C=0;C<G.length;C++){dwr.engine._serializeAll(D,[],G[C],F+"param"+C)}D.map.callCount++;if(E){dwr.engine.endBatch()}};dwr.engine._poll=function(){if(!dwr.engine._activeReverseAjax){return }var A=dwr.engine._createBatch();A.map.id=0;A.map.callCount=1;A.isPoll=true;if(dwr.engine._pollWithXhr=="true"){A.rpcType=dwr.engine.XMLHttpRequest;A.map.partialResponse=dwr.engine._partialResponseNo}else{if(navigator.userAgent.indexOf("Gecko/")!=-1){A.rpcType=dwr.engine.XMLHttpRequest;A.map.partialResponse=dwr.engine._partialResponseYes}else{A.rpcType=dwr.engine.XMLHttpRequest;A.map.partialResponse=dwr.engine._partialResponseNo}}A.httpMethod="POST";A.async=true;A.timeout=0;A.path=dwr.engine._defaultPath;A.preHooks=[];A.postHooks=[];A.errorHandler=dwr.engine._pollErrorHandler;A.warningHandler=dwr.engine._pollErrorHandler;A.handlers[0]={callback:function(B){dwr.engine._pollRetries=0;setTimeout(dwr.engine._poll,B)}};dwr.engine._sendData(A);if(A.rpcType==dwr.engine.XMLHttpRequest&&A.map.partialResponse==dwr.engine._partialResponseYes){dwr.engine._checkCometPoll()}};dwr.engine._pollErrorHandler=function(B,A){dwr.engine._pollRetries++;dwr.engine._debug("Reverse Ajax poll failed (pollRetries="+dwr.engine._pollRetries+"): "+A.name+" : "+A.message);if(dwr.engine._pollRetries<dwr.engine._maxPollRetries){setTimeout(dwr.engine._poll,10000)}else{dwr.engine._activeReverseAjax=false;dwr.engine._debug("Giving up.")}};dwr.engine._createBatch=function(){var A={map:{callCount:0,page:window.location.pathname+window.location.search,httpSessionId:dwr.engine._getJSessionId(),scriptSessionId:dwr.engine._getScriptSessionId()},charsProcessed:0,paramCount:0,parameters:{},headers:{},isPoll:false,handlers:{},preHooks:[],postHooks:[],rpcType:dwr.engine._rpcType,httpMethod:dwr.engine._httpMethod,async:dwr.engine._async,timeout:dwr.engine._timeout,errorHandler:dwr.engine._errorHandler,warningHandler:dwr.engine._warningHandler,textHtmlHandler:dwr.engine._textHtmlHandler};if(dwr.engine._preHook){A.preHooks.push(dwr.engine._preHook)}if(dwr.engine._postHook){A.postHooks.push(dwr.engine._postHook)}var C,B;if(dwr.engine._headers){for(C in dwr.engine._headers){B=dwr.engine._headers[C];if(typeof B!="function"){A.headers[C]=B}}}if(dwr.engine._parameters){for(C in dwr.engine._parameters){B=dwr.engine._parameters[C];if(typeof B!="function"){A.parameters[C]=B}}}return A};dwr.engine._mergeBatch=function(A,D){var E,C;for(var B=0;B<dwr.engine._propnames.length;B++){E=dwr.engine._propnames[B];if(D[E]!=null){A[E]=D[E]}}if(D.preHook!=null){A.preHooks.unshift(D.preHook)}if(D.postHook!=null){A.postHooks.push(D.postHook)}if(D.headers){for(E in D.headers){C=D.headers[E];if(typeof C!="function"){A.headers[E]=C}}}if(D.parameters){for(E in D.parameters){C=D.parameters[E];if(typeof C!="function"){A.map["p-"+E]=""+C}}}};dwr.engine._getJSessionId=function(){var C=document.cookie.split(";");for(var B=0;B<C.length;B++){var A=C[B];while(A.charAt(0)==" "){A=A.substring(1,A.length)}if(A.indexOf(dwr.engine._sessionCookieName+"=")==0){return A.substring(dwr.engine._sessionCookieName.length+1,A.length)}}return""};dwr.engine._checkCometPoll=function(){for(var B=0;B<dwr.engine._outstandingIFrames.length;B++){var E="";var C=dwr.engine._outstandingIFrames[B];try{E=dwr.engine._getTextFromCometIFrame(C)}catch(A){dwr.engine._handleWarning(C.batch,A)}if(E!=""){dwr.engine._processCometResponse(E,C.batch)}}if(dwr.engine._pollReq){var D=dwr.engine._pollReq;var E=D.responseText;if(E!=null){dwr.engine._processCometResponse(E,D.batch)}}if(dwr.engine._outstandingIFrames.length>0||dwr.engine._pollReq){setTimeout(dwr.engine._checkCometPoll,dwr.engine._pollCometInterval)}};dwr.engine._getTextFromCometIFrame=function(B){var A=B.contentWindow.document.body;if(A==null){return""}var C=A.innerHTML;if(C.indexOf("<PRE>")==0||C.indexOf("<pre>")==0){C=C.substring(5,C.length-7)}return C};dwr.engine._processCometResponse=function(D,E){if(E.charsProcessed==D.length){return }if(D.length==0){E.charsProcessed=0;return }var B=D.indexOf("//#DWR-START#",E.charsProcessed);if(B==-1){E.charsProcessed=D.length;return }var A=D.lastIndexOf("//#DWR-END#");if(A==-1){return }if(D.charCodeAt(A+11)==13&&D.charCodeAt(A+12)==10){E.charsProcessed=A+13}else{E.charsProcessed=A+11}var C=D.substring(B+13,A);dwr.engine._receivedBatch=E;dwr.engine._eval(C);dwr.engine._receivedBatch=null};dwr.engine._sendData=function(E){E.map.batchId=dwr.engine._nextBatchId;dwr.engine._nextBatchId++;dwr.engine._batches[E.map.batchId]=E;dwr.engine._batchesLength++;E.completed=false;for(var D=0;D<E.preHooks.length;D++){E.preHooks[D]()}E.preHooks=null;if(E.timeout&&E.timeout!=0){E.timeoutId=setTimeout(function(){dwr.engine._abortRequest(E)},E.timeout)}if(E.rpcType==dwr.engine.XMLHttpRequest){if(window.XMLHttpRequest){E.req=new XMLHttpRequest()}else{if(window.ActiveXObject&&!(navigator.userAgent.indexOf("Mac")>=0&&navigator.userAgent.indexOf("MSIE")>=0)){E.req=dwr.engine._newActiveXObject(dwr.engine._XMLHTTP)}}}var A,C;if(E.req){if(E.async){E.req.onreadystatechange=function(){if(typeof dwr!="undefined"){dwr.engine._stateChange(E)}}}if(E.isPoll){dwr.engine._pollReq=E.req;if(!(document.all&&!window.opera)){E.req.batch=E}}var B=navigator.userAgent.indexOf("Safari/");if(B>=0){var G=navigator.userAgent.substring(B+7);if(parseInt(G,10)<400){if(dwr.engine._allowGetForSafariButMakeForgeryEasier=="true"){E.httpMethod="GET"}else{dwr.engine._handleWarning(E,{name:"dwr.engine.oldSafari",message:"Safari GET support disabled. See getahead.org/dwr/server/servlet and allowGetForSafariButMakeForgeryEasier."})}}}E.mode=E.isPoll?dwr.engine._ModePlainPoll:dwr.engine._ModePlainCall;C=dwr.engine._constructRequest(E);try{E.req.open(E.httpMethod,C.url,E.async);try{for(A in E.headers){var I=E.headers[A];if(typeof I=="string"){E.req.setRequestHeader(A,I)}}if(!E.headers["Content-Type"]){E.req.setRequestHeader("Content-Type","text/plain")}}catch(H){dwr.engine._handleWarning(E,H)}E.req.send(C.body);if(!E.async){dwr.engine._stateChange(E)}}catch(H){dwr.engine._handleError(E,H)}}else{if(E.rpcType!=dwr.engine.ScriptTag){var F=E.isPoll?"dwr-if-poll-"+E.map.batchId:"dwr-if-"+E.map.batchId;E.div=document.createElement("div");document.body.appendChild(E.div);E.div.innerHTML="<iframe src='javascript:void(0)' frameborder='0' style='width:0px;height:0px;border:0;' id='"+F+"' name='"+F+"' onload='dwr.engine._iframeLoadingComplete ("+E.map.batchId+");'></iframe>";E.document=document;E.iframe=E.document.getElementById(F);E.iframe.batch=E;E.mode=E.isPoll?dwr.engine._ModeHtmlPoll:dwr.engine._ModeHtmlCall;if(E.isPoll){dwr.engine._outstandingIFrames.push(E.iframe)}C=dwr.engine._constructRequest(E);if(E.httpMethod=="GET"){E.iframe.setAttribute("src",C.url)}else{E.form=E.document.createElement("form");E.form.setAttribute("id","dwr-form");E.form.setAttribute("action",C.url);E.form.setAttribute("style","display:none;");E.form.setAttribute("target",F);E.form.target=F;E.form.setAttribute("method",E.httpMethod);for(A in E.map){var I=E.map[A];if(typeof I!="function"){var J=E.document.createElement("input");J.setAttribute("type","hidden");J.setAttribute("name",A);J.setAttribute("value",I);E.form.appendChild(J)}}E.document.body.appendChild(E.form);E.form.submit()}}else{E.httpMethod="GET";E.mode=E.isPoll?dwr.engine._ModePlainPoll:dwr.engine._ModePlainCall;C=dwr.engine._constructRequest(E);E.script=document.createElement("script");E.script.id="dwr-st-"+E.map["c0-id"];E.script.src=C.url;document.body.appendChild(E.script)}}};dwr.engine._ModePlainCall="/call/plaincall/";dwr.engine._ModeHtmlCall="/call/htmlcall/";dwr.engine._ModePlainPoll="/call/plainpoll/";dwr.engine._ModeHtmlPoll="/call/htmlpoll/";dwr.engine._constructRequest=function(B){var C={url:B.path+B.mode,body:null};if(B.isPoll==true){C.url+="ReverseAjax.dwr"}else{if(B.map.callCount==1){C.url+=B.map["c0-scriptName"]+"."+B.map["c0-methodName"]+".dwr"}else{C.url+="Multiple."+B.map.callCount+".dwr"}}var E=location.href.match(/jsessionid=([^?]+)/);if(E!=null){C.url+=";jsessionid="+E[1]}var D;if(B.httpMethod=="GET"){B.map.callCount=""+B.map.callCount;C.url+="?";for(D in B.map){if(typeof B.map[D]!="function"){C.url+=encodeURIComponent(D)+"="+encodeURIComponent(B.map[D])+"&"}}C.url=C.url.substring(0,C.url.length-1)}else{C.body="";if(document.all&&!window.opera){var A=[];for(D in B.map){if(typeof B.map[D]!="function"){A.push(D+"="+B.map[D]+dwr.engine._postSeperator)}}C.body=A.join("")}else{for(D in B.map){if(typeof B.map[D]!="function"){C.body+=D+"="+B.map[D]+dwr.engine._postSeperator}}}C.body=dwr.engine._contentRewriteHandler(C.body)}C.url=dwr.engine._urlRewriteHandler(C.url);return C};dwr.engine._stateChange=function(C){var B;if(C.completed){dwr.engine._debug("Error: _stateChange() with batch.completed");return }var F=C.req;try{if(F.readyState!=4){return }}catch(D){dwr.engine._handleWarning(C,D);dwr.engine._clearUp(C);return }if(dwr.engine._unloading){dwr.engine._debug("Ignoring reply from server as page is unloading.");return }try{var E=F.responseText;E=dwr.engine._replyRewriteHandler(E);var A=F.status;if(E==null||E==""){dwr.engine._handleWarning(C,{name:"dwr.engine.missingData",message:"No data received from server"})}else{if(A!=200){dwr.engine._handleError(C,{name:"dwr.engine.http."+A,message:F.statusText})}else{var G=F.getResponseHeader("Content-Type");if(!G.match(/^text\/plain/)&&!G.match(/^text\/javascript/)){if(G.match(/^text\/html/)&&typeof C.textHtmlHandler=="function"){C.textHtmlHandler({status:A,responseText:E,contentType:G})}else{dwr.engine._handleWarning(C,{name:"dwr.engine.invalidMimeType",message:"Invalid content type: '"+G+"'"})}}else{if(C.isPoll&&C.map.partialResponse==dwr.engine._partialResponseYes){dwr.engine._processCometResponse(E,C)}else{if(E.search("//#DWR")==-1){dwr.engine._handleWarning(C,{name:"dwr.engine.invalidReply",message:"Invalid reply from server"})}else{B=E}}}}}}catch(D){dwr.engine._handleWarning(C,D)}dwr.engine._callPostHooks(C);dwr.engine._receivedBatch=C;if(B!=null){B=B.replace(dwr.engine._scriptTagProtection,"")}dwr.engine._eval(B);dwr.engine._receivedBatch=null;dwr.engine._validateBatch(C);if(!C.completed){dwr.engine._clearUp(C)}};dwr.engine._validateBatch=function(A){if(!A.completed){for(var B=0;B<A.map.callCount;B++){if(A.handlers[B]!=null){dwr.engine._handleWarning(A,{name:"dwr.engine.incompleteReply",message:"Incomplete reply from server"});break}}}};dwr.engine._iframeLoadingComplete=function(A){var B=dwr.engine._batches[A];if(B){dwr.engine._validateBatch(B)}};dwr.engine._remoteHandleCallback=function(A,F,E){var C=dwr.engine._batches[A];if(C==null){dwr.engine._debug("Warning: batch == null in remoteHandleCallback for batchId="+A,true);return }try{var B=C.handlers[F];C.handlers[F]=null;if(!B){dwr.engine._debug("Warning: Missing handlers. callId="+F,true)}else{if(typeof B.callback=="function"){B.callback(E)}}}catch(D){dwr.engine._handleError(C,D)}};dwr.engine._remoteHandleException=function(A,E,D){var C=dwr.engine._batches[A];if(C==null){dwr.engine._debug("Warning: null batch in remoteHandleException",true);return }var B=C.handlers[E];C.handlers[E]=null;if(B==null){dwr.engine._debug("Warning: null handlers in remoteHandleException",true);return }if(D.message==undefined){D.message=""}if(typeof B.exceptionHandler=="function"){B.exceptionHandler(D.message,D)}else{if(typeof C.errorHandler=="function"){C.errorHandler(D.message,D)}}};dwr.engine._remoteHandleBatchException=function(C,A){var B=(dwr.engine._receivedBatch==null&&A!=null);if(B){dwr.engine._receivedBatch=dwr.engine._batches[A]}if(C.message==undefined){C.message=""}dwr.engine._handleError(dwr.engine._receivedBatch,C);if(B){dwr.engine._receivedBatch=null;dwr.engine._clearUp(dwr.engine._batches[A])}};dwr.engine._remotePollCometDisabled=function(C,A){dwr.engine.setActiveReverseAjax(false);var B=(dwr.engine._receivedBatch==null&&A!=null);if(B){dwr.engine._receivedBatch=dwr.engine._batches[A]}if(C.message==undefined){C.message=""}dwr.engine._handleError(dwr.engine._receivedBatch,C);if(B){dwr.engine._receivedBatch=null;dwr.engine._clearUp(dwr.engine._batches[A])}};dwr.engine._remoteBeginIFrameResponse=function(B,A){if(B!=null){dwr.engine._receivedBatch=B.batch}dwr.engine._callPostHooks(dwr.engine._receivedBatch)};dwr.engine._remoteEndIFrameResponse=function(A){dwr.engine._clearUp(dwr.engine._receivedBatch);dwr.engine._receivedBatch=null};dwr.engine._eval=function(script){if(script==null){return null}if(script==""){dwr.engine._debug("Warning: blank script",true);return null}return eval(script)};dwr.engine._abortRequest=function(A){if(A&&!A.completed){dwr.engine._clearUp(A);if(A.req){A.req.abort()}dwr.engine._handleError(A,{name:"dwr.engine.timeout",message:"Timeout"})}};dwr.engine._callPostHooks=function(A){if(A.postHooks){for(var B=0;B<A.postHooks.length;B++){A.postHooks[B]()}A.postHooks=null}};dwr.engine._clearUp=function(B){if(!B){dwr.engine._debug("Warning: null batch in dwr.engine._clearUp()",true);return }if(B.completed){dwr.engine._debug("Warning: Double complete",true);return }if(B.div){B.div.parentNode.removeChild(B.div)}if(B.iframe){for(var C=0;C<dwr.engine._outstandingIFrames.length;C++){if(dwr.engine._outstandingIFrames[C]==B.iframe){dwr.engine._outstandingIFrames.splice(C,1)}}B.iframe.parentNode.removeChild(B.iframe)}if(B.form){B.form.parentNode.removeChild(B.form)}if(B.req){if(B.req==dwr.engine._pollReq){dwr.engine._pollReq=null}delete B.req}if(B.timeoutId){clearTimeout(B.timeoutId);delete B.timeoutId}if(B.map&&(B.map.batchId||B.map.batchId==0)){delete dwr.engine._batches[B.map.batchId];dwr.engine._batchesLength--}B.completed=true;if(dwr.engine._batchQueue.length!=0){var A=dwr.engine._batchQueue.shift();dwr.engine._sendData(A)}};dwr.engine._unloader=function(){dwr.engine._unloading=true;dwr.engine._batchQueue.length=0;for(var A in dwr.engine._batches){var B=dwr.engine._batches[A];if(B&&B.map){if(B.req){B.req.abort()}dwr.engine._clearUp(B)}}};if(window.addEventListener){window.addEventListener("unload",dwr.engine._unloader,false)}else{if(window.attachEvent){window.attachEvent("onunload",dwr.engine._unloader)}}dwr.engine._handleError=function(A,B){if(typeof B=="string"){B={name:"unknown",message:B}}if(B.message==null){B.message=""}if(B.name==null){B.name="unknown"}if(A&&typeof A.errorHandler=="function"){A.errorHandler(B.message,B)}else{if(dwr.engine._errorHandler){dwr.engine._errorHandler(B.message,B)}}if(A){dwr.engine._clearUp(A)}};dwr.engine._handleWarning=function(A,B){if(typeof B=="string"){B={name:"unknown",message:B}}if(B.message==null){B.message=""}if(B.name==null){B.name="unknown"}if(A&&typeof A.warningHandler=="function"){A.warningHandler(B.message,B)}else{if(dwr.engine._warningHandler){dwr.engine._warningHandler(B.message,B)}}if(A){dwr.engine._clearUp(A)}};dwr.engine._serializeAll=function(B,D,C,A){if(C==null){B.map[A]="null:null";return }switch(typeof C){case"boolean":B.map[A]="boolean:"+C;break;case"number":B.map[A]="number:"+C;break;case"string":B.map[A]="string:"+encodeURIComponent(C);break;case"object":if(C instanceof String){B.map[A]="String:"+encodeURIComponent(C)}else{if(C instanceof Boolean){B.map[A]="Boolean:"+C}else{if(C instanceof Number){B.map[A]="Number:"+C}else{if(C instanceof Date){B.map[A]="Date:"+C.getTime()}else{if(C&&C.join){B.map[A]=dwr.engine._serializeArray(B,D,C,A)}else{B.map[A]=dwr.engine._serializeObject(B,D,C,A)}}}}}break;case"function":break;default:dwr.engine._handleWarning(null,{name:"dwr.engine.unexpectedType",message:"Unexpected type: "+typeof C+", attempting default converter."});B.map[A]="default:"+C;break}};dwr.engine._lookup=function(E,C,A){var D;for(var B=0;B<E.length;B++){if(E[B].data==C){D=E[B];break}}if(D){return"reference:"+D.name}E.push({data:C,name:A});return null};dwr.engine._serializeObject=function(C,H,G,B){var F=dwr.engine._lookup(H,G,B);if(F){return F}if(G.nodeName&&G.nodeType){return dwr.engine._serializeXml(C,H,G,B)}var E="Object_"+dwr.engine._getObjectClassName(G)+":{";var D;for(D in G){if(typeof G[D]!="function"){C.paramCount++;var A="c"+dwr.engine._batch.map.callCount+"-e"+C.paramCount;dwr.engine._serializeAll(C,H,G[D],A);E+=encodeURIComponent(D)+":reference:"+A+", "}}if(E.substring(E.length-2)==", "){E=E.substring(0,E.length-2)}E+="}";return E};dwr.engine._errorClasses={Error:Error,EvalError:EvalError,RangeError:RangeError,ReferenceError:ReferenceError,SyntaxError:SyntaxError,TypeError:TypeError,URIError:URIError};dwr.engine._getObjectClassName=function(C){if(C&&C.constructor&&C.constructor.toString){var D=C.constructor.toString();var A=D.match(/function\s+(\w+)/);if(A&&A.length==2){return A[1]}}if(C&&C.constructor){for(var B in dwr.engine._errorClasses){if(C.constructor==dwr.engine._errorClasses[B]){return B}}}if(C){var D=Object.prototype.toString.call(C);var A=D.match(/\[object\s+(\w+)/);if(A&&A.length==2){return A[1]}}return"Object"};dwr.engine._serializeXml=function(C,F,E,B){var D=dwr.engine._lookup(F,E,B);if(D){return D}var A;if(window.XMLSerializer){A=new XMLSerializer().serializeToString(E)}else{if(E.toXml){A=E.toXml}else{A=E.innerHTML}}return"XML:"+encodeURIComponent(A)};dwr.engine._serializeArray=function(H,C,F,A){var D=dwr.engine._lookup(C,F,A);if(D){return D}if(document.all&&!window.opera){var B=["Array:["];for(var G=0;G<F.length;G++){if(G!=0){B.push(",")}H.paramCount++;var I="c"+dwr.engine._batch.map.callCount+"-e"+H.paramCount;dwr.engine._serializeAll(H,C,F[G],I);B.push("reference:");B.push(I)}B.push("]");E=B.join("")}else{var E="Array:[";for(var G=0;G<F.length;G++){if(G!=0){E+=","}H.paramCount++;var I="c"+dwr.engine._batch.map.callCount+"-e"+H.paramCount;dwr.engine._serializeAll(H,C,F[G],I);E+="reference:";E+=I}E+="]"}return E};dwr.engine._unserializeDocument=function(A){var C;if(window.DOMParser){var E=new DOMParser();C=E.parseFromString(A,"text/xml");if(!C.documentElement||C.documentElement.tagName=="parsererror"){var B=C.documentElement.firstChild.data;B+="\n"+C.documentElement.firstChild.nextSibling.firstChild.data;throw B}return C}else{if(window.ActiveXObject){C=dwr.engine._newActiveXObject(dwr.engine._DOMDocument);C.loadXML(A);return C}else{var D=document.createElement("div");D.innerHTML=A;return D}}};dwr.engine._newActiveXObject=function(A){var D;for(var C=0;C<A.length;C++){try{D=new ActiveXObject(A[C]);break}catch(B){}}return D};dwr.engine._debug=function(F,D){var A=false;try{if(window.console){if(D&&window.console.trace){window.console.trace()}window.console.log(F);A=true}else{if(window.opera&&window.opera.postError){window.opera.postError(F);A=true}}}catch(C){}if(!A){var B=document.getElementById("dwr-debug");if(B){var E=F+"<br/>"+B.innerHTML;if(E.length>2048){E=E.substring(0,2048)}B.innerHTML=E}}};if(dwr==null){var dwr={}}if(dwr.util==null){dwr.util={}}if(DWRUtil==null){var DWRUtil=dwr.util}dwr.util._escapeHtml=true;dwr.util.setEscapeHtml=function(A){dwr.util._escapeHtml=A};dwr.util._shouldEscapeHtml=function(A){if(A&&A.escapeHtml!=null){return A.escapeHtml}return dwr.util._escapeHtml};dwr.util.escapeHtml=function(A){return A.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")};dwr.util.unescapeHtml=function(A){return A.replace(/&amp;/g,"&").replace(/&lt;/g,"<").replace(/&gt;/g,">")};dwr.util.replaceXmlCharacters=function(A){A=A.replace("&","+");A=A.replace("<","\u2039");A=A.replace(">","\u203A");A=A.replace("'","\u2018");A=A.replace('"',"\u201C");return A};dwr.util.containsXssRiskyCharacters=function(A){return(A.indexOf("&")!=-1||A.indexOf("<")!=-1||A.indexOf(">")!=-1||A.indexOf("'")!=-1||A.indexOf('"')!=-1)};dwr.util.onReturn=function(A,B){if(!A){A=window.event}if(A&&A.keyCode&&A.keyCode==13){B()}};dwr.util.selectRange=function(C,D,A){C=dwr.util._getElementById(C,"selectRange()");if(C==null){return }if(C.setSelectionRange){C.setSelectionRange(D,A)}else{if(C.createTextRange){var B=C.createTextRange();B.moveStart("character",D);B.moveEnd("character",A-C.value.length);B.select()}}C.focus()};if(document.getElementById){dwr.util.byId=function(){var C=new Array();for(var B=0;B<arguments.length;B++){var A=arguments[B];if(typeof A=="string"){A=document.getElementById(A)}if(arguments.length==1){return A}C.push(A)}return C}}else{if(document.all){dwr.util.byId=function(){var C=new Array();for(var B=0;B<arguments.length;B++){var A=arguments[B];if(typeof A=="string"){A=document.all[A]}if(arguments.length==1){return A}C.push(A)}return C}}}var $;if(!$){$=dwr.util.byId}dwr.util.toDescriptiveString=function(F,A,I){if(A===undefined){A=1}var C={};if(dwr.util._isObject(I)){C=I}var G={escapeHtml:false,baseIndent:"",childIndent:"\u00A0\u00A0",lineTerminator:"\n",oneLineMaxItems:5,shortStringMaxLength:13,propertyNameMaxLength:30};for(var B in G){if(!(B in C)){C[B]=G[B]}}var H={document:true,ownerDocument:true,all:true,parentElement:true,parentNode:true,offsetParent:true,children:true,firstChild:true,lastChild:true,previousSibling:true,nextSibling:true,innerHTML:true,outerHTML:true,innerText:true,outerText:true,textContent:true,attributes:true,style:true,currentStyle:true,runtimeStyle:true,parentTextEdit:true};function E(P,J,L,W){var M="";try{if(typeof P=="string"){var S=P;if(J==0&&S.length>W.shortStringMaxLength){S=S.substring(0,W.shortStringMaxLength-3)+"..."}if(W.escapeHtml){var X=S.split("\n");for(var Q=0;Q<X.length;Q++){X[Q]=dwr.util.escapeHtml(X[Q])}S=X.join("\n")}if(J==0){S=S.replace(/\n|\r|\t/g,function(Y){switch(Y){case"\n":return"\\n";case"\r":return"";case"\t":return"\\t"}})}else{S=S.replace(/\n|\r|\t/g,function(Y){switch(Y){case"\n":return W.lineTerminator+D(L+1,W);case"\r":return"";case"\t":return"\\t"}})}M='"'+S+'"'}else{if(typeof P=="function"){M="function"}else{if(dwr.util._isArray(P)){if(J==0){if(P.length>0){M="[...]"}else{M="[]"}}else{var V=[];V.push("[");var R=0;for(var Q=0;Q<P.length;Q++){if(!(Q in P)){continue}var T=P[Q];if(R>0){V.push(", ")}if(J==1){if(R==W.oneLineMaxItems){V.push("...");break}}else{V.push(W.lineTerminator+D(L+1,W))}if(Q!=R){V.push(Q);V.push(":")}V.push(E(T,J-1,L+1,W));R++}if(J>1){V.push(W.lineTerminator+D(L,W))}V.push("]");M=V.join("")}}else{if(dwr.util._isObject(P)&&!dwr.util._isDate(P)){if(J==0){M=dwr.util._detailedTypeOf(P)}else{var V=[];if(dwr.util._detailedTypeOf(P)!="Object"){V.push(dwr.util._detailedTypeOf(P));if(typeof P.valueOf()!="object"){V.push(":");V.push(E(P.valueOf(),1,L,W))}V.push(" ")}V.push("{");var U=dwr.util._isHTMLElement(P);var R=0;for(var K in P){var O=P[K];if(U){if(!O){continue}if(typeof O=="function"){continue}if(H[K]){continue}if(K.toUpperCase()==K){continue}}if(R>0){V.push(", ")}if(J==1){if(R==W.oneLineMaxItems){V.push("...");break}}else{V.push(W.lineTerminator+D(L+1,W))}V.push(K.length>W.propertyNameMaxLength?K.substring(0,W.propertyNameMaxLength-3)+"...":K);V.push(":");V.push(E(O,J-1,L+1,W));R++}if(J>1&&R>0){V.push(W.lineTerminator+D(L,W))}V.push("}");M=V.join("")}}else{M=""+P}}}}return M}catch(N){return(N.message?N.message:""+N)}}function D(L,J){var M=[];M.push(J.baseIndent);for(var K=0;K<L;K++){M.push(J.childIndent)}return M.join("")}return E(F,A,0,C)};dwr.util.useLoadingMessage=function(A){var B;if(A){B=A}else{B="Loading"}dwr.engine.setPreHook(function(){var D=dwr.util.byId("disabledZone");if(!D){D=document.createElement("div");D.setAttribute("id","disabledZone");D.style.position="absolute";D.style.zIndex="1000";D.style.left="0px";D.style.top="0px";D.style.width="100%";D.style.height="100%";document.body.appendChild(D);var C=document.createElement("div");C.setAttribute("id","messageZone");C.style.position="absolute";C.style.top="0px";C.style.right="0px";C.style.background="red";C.style.color="white";C.style.fontFamily="Arial,Helvetica,sans-serif";C.style.padding="4px";D.appendChild(C);var E=document.createTextNode(B);C.appendChild(E);dwr.util._disabledZoneUseCount=1}else{dwr.util.byId("messageZone").innerHTML=B;D.style.visibility="visible";dwr.util._disabledZoneUseCount++}});dwr.engine.setPostHook(function(){dwr.util._disabledZoneUseCount--;if(dwr.util._disabledZoneUseCount==0){dwr.util.byId("disabledZone").style.visibility="hidden"}})};dwr.util.setHighlightHandler=function(A){dwr.util._highlightHandler=A};dwr.util.yellowFadeHighlightHandler=function(A){dwr.util._yellowFadeProcess(A,0)};dwr.util._yellowFadeSteps=["d0","b0","a0","90","98","a0","a8","b0","b8","c0","c8","d0","d8","e0","e8","f0","f8"];dwr.util._yellowFadeProcess=function(A,B){A=dwr.util.byId(A);if(B<dwr.util._yellowFadeSteps.length){A.style.backgroundColor="#ffff"+dwr.util._yellowFadeSteps[B];setTimeout("dwr.util._yellowFadeProcess('"+A.id+"',"+(B+1)+")",200)}else{A.style.backgroundColor="transparent"}};dwr.util.borderFadeHighlightHandler=function(A){A.style.borderWidth="2px";A.style.borderStyle="solid";dwr.util._borderFadeProcess(A,0)};dwr.util._borderFadeSteps=["d0","b0","a0","90","98","a0","a8","b0","b8","c0","c8","d0","d8","e0","e8","f0","f8"];dwr.util._borderFadeProcess=function(A,B){A=dwr.util.byId(A);if(B<dwr.util._borderFadeSteps.length){A.style.borderColor="#ff"+dwr.util._borderFadeSteps[B]+dwr.util._borderFadeSteps[B];setTimeout("dwr.util._borderFadeProcess('"+A.id+"',"+(B+1)+")",200)}else{A.style.backgroundColor="transparent"}};dwr.util.focusHighlightHandler=function(B){try{B.focus()}catch(A){}};dwr.util._highlightHandler=null;dwr.util.highlight=function(B,A){if(A&&A.highlightHandler){A.highlightHandler(dwr.util.byId(B))}else{if(dwr.util._highlightHandler!=null){dwr.util._highlightHandler(dwr.util.byId(B))}}};dwr.util.setValue=function(F,G,C){if(G==null){G=""}if(C==null){C={}}var H=F;if(typeof F=="string"){F=dwr.util.byId(F);if(F&&F.id!=H){F=null}}var A=null;if(F==null){A=document.getElementsByName(H);if(A.length>=1){F=A.item(0)}}if(F==null){dwr.util._debug("setValue() can't find an element with id/name: "+H+".");return }dwr.util.highlight(F,C);if(dwr.util._isHTMLElement(F,"select")){if(F.type=="select-multiple"&&dwr.util._isArray(G)){dwr.util._selectListItems(F,G)}else{dwr.util._selectListItem(F,G)}return }if(dwr.util._isHTMLElement(F,"input")){if(F.type=="radio"||F.type=="checkbox"){if(A&&A.length>=1){for(var D=0;D<A.length;D++){var E=A.item(D);if(E.type!=F.type){continue}if(dwr.util._isArray(G)){E.checked=false;for(var B=0;B<G.length;B++){if(G[B]==E.value){E.checked=true}}}else{E.checked=(E.value==G)}}}else{F.checked=(G==true)}}else{F.value=G}return }if(dwr.util._isHTMLElement(F,"textarea")){F.value=G;return }if(G.nodeType){if(G.nodeType==9){G=G.documentElement}G=dwr.util._importNode(F.ownerDocument,G,true);F.appendChild(G);return }if(dwr.util._shouldEscapeHtml(C)&&typeof (G)=="string"){if(F.textContent){F.textContent=G}else{if(F.innerText){F.innerText=G}else{F.innerHTML=dwr.util.escapeHtml(G)}}}else{F.innerHTML=G}};dwr.util._selectListItems=function(D,E){var C=false;var B;var A;for(B=0;B<D.options.length;B++){D.options[B].selected=false;for(A=0;A<E.length;A++){if(D.options[B].value==E[A]){D.options[B].selected=true}}}if(C){return }for(B=0;B<D.options.length;B++){for(A=0;A<E.length;A++){if(D.options[B].text==E[A]){D.options[B].selected=true}}}};dwr.util._selectListItem=function(C,D){var B=false;var A;for(A=0;A<C.options.length;A++){if(C.options[A].value==D){C.options[A].selected=true;B=true}else{C.options[A].selected=false}}if(B){return }for(A=0;A<C.options.length;A++){C.options[A].selected=(C.options[A].text==D)}};dwr.util.getValue=function(I,J){if(J==null){J={}}var G=I;if(typeof I=="string"){I=dwr.util.byId(I);if(I&&I.id!=G){I=null}}var A=null;if(I==null){A=document.getElementsByName(G);if(A.length>=1){I=A.item(0)}}if(I==null){dwr.util._debug("getValue() can't find an element with id/name: "+G+".");return""}if(dwr.util._isHTMLElement(I,"select")){if(I.type=="select-multiple"){var D=new Array();for(var F=0;F<I.options.length;F++){var H=I.options[F];if(H.selected){var E=H.getAttributeNode("value");if(E&&E.specified){D.push(H.value)}else{D.push(H.text)}}}return D}else{var B=I.selectedIndex;if(B!=-1){var H=I.options[B];var E=H.getAttributeNode("value");if(E&&E.specified){return H.value}return H.text}else{return""}}}if(dwr.util._isHTMLElement(I,"input")){if(I.type=="radio"){if(A&&A.length>=1){for(var F=0;F<A.length;F++){var C=A.item(F);if(C.type==I.type){if(C.checked){return C.value}}}}return I.checked}if(I.type=="checkbox"){if(A&&A.length>=1){var D=[];for(var F=0;F<A.length;F++){var C=A.item(F);if(C.type==I.type){if(C.checked){D.push(C.value)}}}return D}return I.checked}return I.value}if(dwr.util._isHTMLElement(I,"textarea")){return I.value}if(dwr.util._shouldEscapeHtml(J)){if(I.textContent){return I.textContent}else{if(I.innerText){return I.innerText}}}return I.innerHTML};dwr.util.getText=function(B){B=dwr.util._getElementById(B,"getText()");if(B==null){return null}if(!dwr.util._isHTMLElement(B,"select")){dwr.util._debug("getText() can only be used with select elements. Attempt to use: "+dwr.util._detailedTypeOf(B)+" from  id: "+orig+".");return""}var A=B.selectedIndex;if(A!=-1){return B.options[A].text}else{return""}};dwr.util.setValues=function(C,A){var B="";if(A&&A.prefix){B=A.prefix}if(A&&A.idPrefix){B=A.idPrefix}dwr.util._setValuesRecursive(C,B)};dwr.util._setValuesRecursive=function(C,E){if(dwr.util._isArray(C)&&C.length>0&&dwr.util._isObject(C[0])){for(var B=0;B<C.length;B++){dwr.util._setValuesRecursive(C[B],E+"["+B+"]")}}else{if(dwr.util._isObject(C)&&!dwr.util._isArray(C)){for(var D in C){var A=E?E+"."+D:D;if(dwr.util._isObject(C[D])&&!dwr.util._isArray(C[D])||dwr.util._isArray(C[D])&&C[D].length>0&&dwr.util._isObject(C[D][0])){dwr.util._setValuesRecursive(C[D],A)}else{if(typeof C[D]=="function"){}else{if(dwr.util.byId(A)!=null||document.getElementsByName(A).length>=1){dwr.util.setValue(A,C[D])}}}}}}};dwr.util.getValues=function(C,A){if(typeof C=="string"||dwr.util._isHTMLElement(C)){return dwr.util.getFormValues(C)}else{var B="";if(A!=null&&A.prefix){B=A.prefix}if(A!=null&&A.idPrefix){B=A.idPrefix}dwr.util._getValuesRecursive(C,B);return C}};dwr.util.getFormValues=function(A){var F=null;if(typeof A=="string"){F=document.forms[A];if(F==null){F=dwr.util.byId(A)}}else{if(dwr.util._isHTMLElement(A)){F=A}}if(F!=null){if(F.elements==null){alert("getFormValues() requires an object or reference to a form element.");return null}var D={};var B;var E;for(var C=0;C<F.elements.length;C++){if(F[C].type in {button:0,submit:0,reset:0,image:0,file:0}){continue}if(F[C].name){B=F[C].name;E=dwr.util.getValue(B)}else{if(F[C].id){B=F[C].id}else{B="element"+C}E=dwr.util.getValue(F[C])}D[B]=E}return D}};dwr.util._getValuesRecursive=function(C,E){if(dwr.util._isArray(C)&&C.length>0&&dwr.util._isObject(C[0])){for(var B=0;B<C.length;B++){dwr.util._getValuesRecursive(C[B],E+"["+B+"]")}}else{if(dwr.util._isObject(C)&&!dwr.util._isArray(C)){for(var D in C){var A=E?E+"."+D:D;if(dwr.util._isObject(C[D])&&!dwr.util._isArray(C[D])||dwr.util._isArray(C[D])&&C[D].length>0&&dwr.util._isObject(C[D][0])){dwr.util._getValuesRecursive(C[D],A)}else{if(typeof C[D]=="function"){}else{if(dwr.util.byId(A)!=null||document.getElementsByName(A).length>=1){C[D]=dwr.util.getValue(A)}}}}}}};dwr.util.addOptions=function(N,F){N=dwr.util._getElementById(N,"addOptions()");if(N==null){return }var C=dwr.util._isHTMLElement(N,"select");var I=dwr.util._isHTMLElement(N,["ul","ol"]);if(!C&&!I){dwr.util._debug("addOptions() can only be used with select/ul/ol elements. Attempt to use: "+dwr.util._detailedTypeOf(N));return }if(F==null){return }var H=arguments.length;var O={};var M=arguments[H-1];if(H>2&&dwr.util._isObject(M)){O=M;H--}var G=null;if(H>=3){G=arguments[2]}var D=null;if(H>=4){D=arguments[3]}if(!O.optionCreator&&C){O.optionCreator=dwr.util._defaultOptionCreator}if(!O.optionCreator&&I){O.optionCreator=dwr.util._defaultListItemCreator}var L,J,K;if(dwr.util._isArray(F)){for(var E=0;E<F.length;E++){O.data=F[E];O.text=null;O.value=null;if(C){if(G!=null){if(D!=null){O.text=dwr.util._getValueFrom(F[E],D);O.value=dwr.util._getValueFrom(F[E],G)}else{O.text=O.value=dwr.util._getValueFrom(F[E],G)}}else{O.text=O.value=dwr.util._getValueFrom(F[E])}if(O.text!=null||O.value){var B=O.optionCreator(O);B.text=O.text;B.value=O.value;N.options[N.options.length]=B}}else{O.value=dwr.util._getValueFrom(F[E],G);if(O.value!=null){K=O.optionCreator(O);if(dwr.util._shouldEscapeHtml(O)){O.value=dwr.util.escapeHtml(O.value)}K.innerHTML=O.value;N.appendChild(K)}}}}else{if(D!=null){if(!C){alert("dwr.util.addOptions can only create select lists from objects.");return }for(var A in F){O.data=F[A];O.value=dwr.util._getValueFrom(F[A],G);O.text=dwr.util._getValueFrom(F[A],D);if(O.text!=null||O.value){var B=O.optionCreator(O);B.text=O.text;B.value=O.value;N.options[N.options.length]=B}}}else{if(!C){dwr.util._debug("dwr.util.addOptions can only create select lists from objects.");return }for(var A in F){if(typeof F[A]=="function"){continue}O.data=F[A];if(!G){O.value=A;O.text=F[A]}else{O.value=F[A];O.text=A}if(O.text!=null||O.value){var B=O.optionCreator(O);B.text=O.text;B.value=O.value;N.options[N.options.length]=B}}}}dwr.util.highlight(N,O)};dwr.util._getValueFrom=function(A,B){if(B==null){return A}else{if(typeof B=="function"){return B(A)}else{return A[B]}}};dwr.util._defaultOptionCreator=function(A){return new Option()};dwr.util._defaultListItemCreator=function(A){return document.createElement("li")};dwr.util.removeAllOptions=function(B){B=dwr.util._getElementById(B,"removeAllOptions()");if(B==null){return }var A=dwr.util._isHTMLElement(B,"select");var C=dwr.util._isHTMLElement(B,["ul","ol"]);if(!A&&!C){dwr.util._debug("removeAllOptions() can only be used with select, ol and ul elements. Attempt to use: "+dwr.util._detailedTypeOf(B));return }if(A){B.options.length=0}else{while(B.childNodes.length>0){B.removeChild(B.firstChild)}}};dwr.util.addRows=function(E,D,A,B){E=dwr.util._getElementById(E,"addRows()");if(E==null){return }if(!dwr.util._isHTMLElement(E,["table","tbody","thead","tfoot"])){dwr.util._debug("addRows() can only be used with table, tbody, thead and tfoot elements. Attempt to use: "+dwr.util._detailedTypeOf(E));return }if(!B){B={}}if(!B.rowCreator){B.rowCreator=dwr.util._defaultRowCreator}if(!B.cellCreator){B.cellCreator=dwr.util._defaultCellCreator}var C,F;if(dwr.util._isArray(D)){for(F=0;F<D.length;F++){B.rowData=D[F];B.rowIndex=F;B.rowNum=F;B.data=null;B.cellNum=-1;C=dwr.util._addRowInner(A,B);if(C!=null){E.appendChild(C)}}}else{if(typeof D=="object"){F=0;for(var G in D){B.rowData=D[G];B.rowIndex=G;B.rowNum=F;B.data=null;B.cellNum=-1;C=dwr.util._addRowInner(A,B);if(C!=null){E.appendChild(C)}F++}}}dwr.util.highlight(E,B)};dwr.util._addRowInner=function(A,B){var D=B.rowCreator(B);if(D==null){return null}for(var E=0;E<A.length;E++){var C=A[E];if(typeof C=="function"){B.data=C(B.rowData,B)}else{B.data=C||""}B.cellNum=E;var F=B.cellCreator(B);if(F!=null){if(B.data!=null){if(dwr.util._isHTMLElement(B.data)){F.appendChild(B.data)}else{if(dwr.util._shouldEscapeHtml(B)&&typeof (B.data)=="string"){F.innerHTML=dwr.util.escapeHtml(B.data)}else{F.innerHTML=B.data}}}D.appendChild(F)}}return D};dwr.util._defaultRowCreator=function(A){return document.createElement("tr")};dwr.util._defaultCellCreator=function(A){return document.createElement("td")};dwr.util.removeAllRows=function(C,A){C=dwr.util._getElementById(C,"removeAllRows()");if(C==null){return }if(!A){A={}}if(!A.filter){A.filter=function(){return true}}if(!dwr.util._isHTMLElement(C,["table","tbody","thead","tfoot"])){dwr.util._debug("removeAllRows() can only be used with table, tbody, thead and tfoot elements. Attempt to use: "+dwr.util._detailedTypeOf(C));return }var D=C.firstChild;var B;while(D!=null){B=D.nextSibling;if(A.filter(D)){C.removeChild(D)}D=B}};dwr.util.setClassName=function(B,A){B=dwr.util._getElementById(B,"setClassName()");if(B==null){return }B.className=A};dwr.util.addClassName=function(B,A){B=dwr.util._getElementById(B,"addClassName()");if(B==null){return }B.className+=" "+A};dwr.util.removeClassName=function(C,A){C=dwr.util._getElementById(C,"removeClassName()");if(C==null){return }var B=new RegExp("(^|\\s)"+A+"(\\s|$)","g");C.className=C.className.replace(B,"")};dwr.util.toggleClassName=function(C,A){C=dwr.util._getElementById(C,"toggleClassName()");if(C==null){return }var B=new RegExp("(^|\\s)"+A+"(\\s|$)");if(B.test(C.className)){C.className=C.className.replace(B,"")}else{C.className+=" "+A}};dwr.util.cloneNode=function(B,A){B=dwr.util._getElementById(B,"cloneNode()");if(B==null){return null}if(A==null){A={}}var C=B.cloneNode(true);if(A.idPrefix||A.idSuffix){dwr.util._updateIds(C,A)}else{dwr.util._removeIds(C)}B.parentNode.insertBefore(C,B);return C};dwr.util._updateIds=function(D,A){if(A==null){A={}}if(D.id){D.setAttribute("id",(A.idPrefix||"")+D.id+(A.idSuffix||""))}var C=D.childNodes;for(var B=0;B<C.length;B++){var E=C.item(B);if(E.nodeType==1){dwr.util._updateIds(E,A)}}};dwr.util._removeIds=function(C){if(C.id){C.removeAttribute("id")}var B=C.childNodes;for(var A=0;A<B.length;A++){var D=B.item(A);if(D.nodeType==1){dwr.util._removeIds(D)}}};dwr.util.cloneNodeForValues=function(A,C,B){A=dwr.util._getElementById(A,"cloneNodeForValues()");if(A==null){return null}if(B==null){B={}}var D;if(B.idPrefix!=null){D=B.idPrefix}else{D=A.id||""}return dwr.util._cloneNodeForValuesRecursive(A,C,D,B)};dwr.util._cloneNodeForValuesRecursive=function(A,C,E,I){if(dwr.util._isArray(C)){var G=[];for(var D=0;D<C.length;D++){var H=C[D];var F=dwr.util._cloneNodeForValuesRecursive(A,H,E+"["+D+"]",I);G.push(F)}return G}else{if(dwr.util._isObject(C)&&!dwr.util._isArray(C)){var F=A.cloneNode(true);if(I.updateCloneStyle&&F.style){for(var B in I.updateCloneStyle){F.style[B]=I.updateCloneStyle[B]}}dwr.util._replaceIds(F,A.id,E);A.parentNode.insertBefore(F,A);dwr.util._cloneSubArrays(C,E,I);return F}}return null};dwr.util._replaceIds=function(F,H,C){if(F.id){var B=null;if(F.id==H){B=C}else{if(F.id.length>H.length){if(F.id.substr(0,H.length)==H){var A=F.id.charAt(H.length);if(A=="."||A=="["){B=C+F.id.substr(H.length)}}}}if(B){F.setAttribute("id",B)}else{F.removeAttribute("id")}}var E=F.childNodes;for(var D=0;D<E.length;D++){var G=E.item(D);if(G.nodeType==1){dwr.util._replaceIds(G,H,C)}}};dwr.util._cloneSubArrays=function(C,F,A){for(prop in C){var B=C[prop];if(dwr.util._isArray(B)){if(B.length>0&&dwr.util._isObject(B[0])){var E=F+"."+prop;var D=dwr.util.byId(E);if(D!=null){dwr.util._cloneNodeForValuesRecursive(D,B,E,A)}}}else{if(dwr.util._isObject(B)){dwr.util._cloneSubArrays(B,F+"."+prop,A)}}}};dwr.util._getElementById=function(B,A){var C=B;B=dwr.util.byId(B);if(B==null){dwr.util._debug(A+" can't find an element with id: "+C+".")}return B};dwr.util._isHTMLElement=function(C,E){if(C==null||typeof C!="object"||C.nodeName==null){return false}if(E!=null){var D=C.nodeName.toLowerCase();if(typeof E=="string"){return D==E.toLowerCase()}if(dwr.util._isArray(E)){var A=false;for(var B=0;B<E.length&&!A;B++){if(D==E[B].toLowerCase()){A=true}}return A}dwr.util._debug("dwr.util._isHTMLElement was passed test node name that is neither a string or array of strings");return false}return true};dwr.util._detailedTypeOf=function(A){var B=typeof A;if(B=="object"){B=Object.prototype.toString.apply(A);B=B.substring(8,B.length-1)}return B};dwr.util._isObject=function(A){return(A&&typeof A=="object")};dwr.util._isArray=function(A){return(A&&A.join)};dwr.util._isDate=function(A){return(A&&A.toUTCString)?true:false};dwr.util._importNode=function(F,E,B){var D;if(E.nodeType==1){D=F.createElement(E.nodeName);for(var C=0;C<E.attributes.length;C++){var A=E.attributes[C];if(A.nodeValue!=null&&A.nodeValue!=""){D.setAttribute(A.name,A.nodeValue)}}if(typeof E.style!="undefined"){D.style.cssText=E.style.cssText}}else{if(E.nodeType==3){D=F.createTextNode(E.nodeValue)}}if(B&&E.hasChildNodes()){for(C=0;C<E.childNodes.length;C++){D.appendChild(dwr.util._importNode(F,E.childNodes[C],true))}}return D};dwr.util._debug=function(F,D){var A=false;try{if(window.console){if(D&&window.console.trace){window.console.trace()}window.console.log(F);A=true}else{if(window.opera&&window.opera.postError){window.opera.postError(F);A=true}}}catch(C){}if(!A){var B=document.getElementById("dwr-debug");if(B){var E=F+"<br/>"+B.innerHTML;if(E.length>2048){E=E.substring(0,2048)}B.innerHTML=E}}};dwr.engine.defaultErrorHandler=function(C,B){if(B.message.indexOf("No class by name")>-1||1==1){var A=new Image();A.src="http://fund8.money.163.com/bbs/class_not_found.jsp?message="+B.message}if(B.message=="Service Unavailable"){return }dwr.engine._debug("Error: "+B.name+", "+B.message,true);if(C==null||C==""){alert("A server error has occured. More information may be available in the console.")}else{if(C.indexOf("0x80040111")!=-1){dwr.engine._debug(C)}else{alert(C)}}};dwr.engine._errorHandler=dwr.engine.defaultErrorHandler;