var xmlHttp;var IE=document.all?true:false;var isIE6=navigator.userAgent.indexOf("MSIE 6.0")>-1;createXMLHttpRequest=function(){if(window.ActiveXObject){xmlHttp=new ActiveXObject("Microsoft.XMLHTTP")}else{if(window.XMLHttpRequest){xmlHttp=new XMLHttpRequest()}}if(!xmlHttp){window.alert("不能创建XMLHttpRequest对象实例.");return false}};createXMLHttpRequestByObject=function(a){if(window.ActiveXObject){a=new ActiveXObject("Microsoft.XMLHTTP")}else{if(window.XMLHttpRequest){a=new XMLHttpRequest()}}if(!a){window.alert("不能创建XMLHttpRequest对象实例.");return false}return a};getCursor=function(){var a;if(IE){a=window.event}else{a=arguments[0]}if(a.pageX||a.pageY){curX=a.pageX;curY=a.pageY}else{if(a.clientX||a.clientY){if(document.body.scrollTop>document.documentElement.scrollTop){curY=a.clientY+document.body.scrollTop}else{curY=a.clientY+document.documentElement.scrollTop}if(document.body.scrollLeft>document.documentElement.scrollLeft){curX=a.clientX+document.body.scrollLeft+10}else{curX=a.clientX+document.documentElement.scrollLeft+10}}}};String.prototype.Trim=function(){return this.replace(/^\s*|\s*$/g,"")};KillSpace=function(h){var f=0,d=0,g=0,e=0,c=0;while(f==0){g=h.length;h=h.replace(/(^\s*)|(\s*$)/g,"");d=h.length;if(g==d){e=0}else{e=1}g=h.length;h=h.replace(/(^\u3000*)|(\u3000*$)/g,"");h=h.replace(/(^\ue4c6*)|(\ue4c6*$)/g,"");d=h.length;if(g==d){c=0}else{c=1}if(e==0&&c==0){f=1}else{f=0}}return h};showsec=function(d,b){var c=document.getElementById("seccode");c.value="";var a=document.getElementById(d);str="/Captcha.jpg?random="+Math.random();if(b&&b!=""){str+="&type="+b}a.src=str};showsecNew=function(c,b){var a=document.getElementById(c);str="/Captcha.jpg?random="+Math.random();if(b&&b!=""){str+="&type="+b}a.src=str};setCookie=function(a,c){var b=1;var d=new Date();d.setTime(d.getTime()+b*24*60*60*1000);document.cookie=a+"="+escape(c)+";expire="+d.toGMTString()};checkDocTitle=function(c){if(c==""){return"error0"}var a="(<.*/>)|(<.*>.*</.*>)";if(c.match(a)){return"error2"}var b="[［］【】＞<>〈〉`~!@#＃$%％^&*＊|;；$+]";if(c.match(b)||c.indexOf("\\")!=-1){return"error1"}return"success"};checkAmbigDocTitle=function(c){if(c==""){return"error0"}var a="(<.*/>)|(<.*>.*</.*>)";if(c.match(a)){return"error2"}var b="[［］【】[＞<>\\]〈〉`~!@#＃$%％^&*＊|;；$+]";if(c.match(b)||c.indexOf("\\")!=-1){return"error1"}return"success"};setIframeHeight=function(a){var b=document.getElementById(a);setTimeout(function(){if(document.all||navigator.userAgent.indexOf("Chrome")>-1){b.style.height=b.contentWindow.document.body==null?"0px":(b.contentWindow.document.body.scrollHeight+"px")}else{b.style.height=b.contentDocument.documentElement.scrollHeight+"px"}},200)};HD_getLength=function(c){var a;var b;a=0;for(b=0;b<c.length;b++){if(c.charCodeAt(b)>255){a+=2}else{a++}}return a};HD_subString=function(h,a){var g=0;var c="";var f=/[^\x00-\xff]/g;var b="";var e=h.replace(f,"**").length;for(var d=0;d<e;d++){b=h.charAt(d).toString();if(b.match(f)!=null){g+=2}else{g++}if(g>a){break}c+=b}return c};editpower=function(){var c=createXMLHttpRequestByObject("editXMLhttp");var a=document.getElementById("doc_title").value;var b="/editDocAuth.do?submit_type=1&doc_title="+encodeURI(a);c.open("GET",b,true);c.onreadystatechange=function(){if(c.readyState==4){if(c.status==200){var f=c.responseXML.getElementsByTagName("Flag")[0].firstChild;var e=document.getElementById("doc_title").value;var d="http://www.hudong.com/editdocauth/"+encodeURI(e);if(f!=null&&f.data=="true"){window.location=d}else{if(f!=null&&f.data=="false"){var k=c.responseXML.getElementsByTagName("Reason")[0].firstChild;var h=getCookie("hduser");var g='<div class="various_mobile">';g=g+'<p class="">'+k.data+"</p>";g=g+'<p class="pad_10">请写下您的建议，我们将尽快处理。</p>';g=g+'<textarea name="correct_content" id="correct_content" cols="45" rows="10" class="mar-bottom-10 block"></textarea>';if(h==null){g=g+'<p class="pad_10">如果方便，请您留下联系方式，我们会尽快向你反馈处理结果，你还可能收到我们送出的纪念品。</p>';g=g+'<textarea name="contact_content" id="contact_content" cols="45" rows="5" class="mar-bottom-10 block"></textarea>'}g=g+'<p class="a-c pad_10"><input class="v_middle input" type="button" value="提 交"  onclick="javascript:newsubmitCorrection(\'3\');" />或<a class="pad10" href="javascript:closeFloatWindow();">放弃</a></p></div>';setFloatWindow("为本词条建议：",g,350,false,false)}else{if(f!=null&&f.data=="editing"){window.location=d}else{if(f!=null&&f.data=="locking"){window.location=d}}}}}}};c.send(null)};function getCookie(a){var b=a+"=";if(document.cookie.length>0){offset=document.cookie.indexOf(b);if(offset!=-1){offset+=b.length;end=document.cookie.indexOf(";",offset);if(end==-1){end=document.cookie.length}return unescape(document.cookie.substring(offset,end))}else{return null}}}linkredwin=function(b){var a=document.createElement("form");a.target="_blank";a.method="post";document.body.appendChild(a);a.action="http://www.hudong.com/wiki/"+encodeURI(b);a.submit();a.parentNode.removeChild(a)};replaceSectionSpace=function(){var a=document.getElementById("doc_title").value;$(document).ready(function(){var g=$(".content_h2");var d=0;if(g!=null){d=g.length}var k,b,f;for(var e=0;e<d;e++){var h=g[e].children;if(h){for(var c=0;c<h.length;c++){if(h[c].tagName.toLowerCase()=="h2"){k=h[c].innerHTML;b=a.length;f=k.substring(b+1);h[c].innerHTML=a+"-"+f}}}}})};_setEnlargeImg=function(c){enlargeimg=document.createElement("img");enlargeimg.src="/images/enlarge.gif";enlargeimg.setAttribute("name","enlargegif");enlargeimg.setAttribute("id","enlargegif");var b=0;var a=0;var d=c;while(d.tagName.toLowerCase()!="body"){b+=d.offsetTop;a+=d.offsetLeft;d=d.offsetParent}b+=5;a+=c.offsetWidth-21;if(a<$("#text_right").offset().left){c.parentNode.appendChild(enlargeimg);enlargeimg.style.position="absolute";enlargeimg.style.top=b+"px";enlargeimg.style.left=a+"px"}};setEnlarge=function(){delEnlarge();var e=document.body.getElementsByTagName("img");var b=e.length;if(b>0){for(var a=0;a<((b+1)/2);a++){if(e[a].src.indexOf("att.hudong.com")>0){var d=e[a].parentNode;while(d.parentNode.tagName.toLowerCase()!="li"&&d.tagName.toLowerCase()!="div"){if(d.tagName.toLowerCase()=="a"&&(d.href.indexOf("tupian.hudong.com")>0)){_setEnlargeImg(e[a]);break}else{d=d.parentNode}}}}for(var c=b;c>=((b+1)/2);c--){if(e[c]&&e[c].src&&e[c].src.indexOf("att.hudong.com")>0){var d=e[c].parentNode;while(d.parentNode.tagName.toLowerCase()!="li"&&d.tagName.toLowerCase()!="div"){if(d.tagName.toLowerCase()=="a"&&(d.href.indexOf("tupian.hudong.com")>0)){_setEnlargeImg(e[c]);break}else{d=d.parentNode}}}}}};delEnlarge=function(){var a=document.getElementsByName("enlargegif");while(a.length>0){a[0].parentNode.removeChild(a[0]);delEnlarge()}};gotoFigure=function(){var b=window.location.href;var c=b.indexOf("#");if(c!=-1){var a=new Array();a=b.split("#");if(a.length==2&&a[1]=="_figurea"){window.location.hash="#_figurea"}}};body_resize=function(){var a=document.documentElement.clientWidth||document.body.clientWidth;var b=document.getElementsByTagName("BODY")[0];if(a>1440){b.style.width=""}else{if(a<=1024){b.style.marginLeft="10px";b.style.marginRight="10px";if(isIE6){b.style.width="950px"}}else{b.style.width=""}}};if(isIE6){setInterval(function(){body_resize()},2000)}var loadviewDocTopicjsflag=false;var loadperfectcordocjsflag=false;var loaddoccontestjsflag=false;var loadviewdocfunctionjsflag=false;var loaddocTagjsflag=false;var loaddocThesaurusjsflag=false;var loadallcerrectionjsflag=false;var loaddoccatalogjsflag=false;var loaddocinfotempletjsflag=false;var loadLockjsflag=false;var loadjqueryformjsflag=false;$(document).ready(function(){initVars();jQuery.getScript("/js/alertwin.js");$("#topic_title").focus(function(){if(loadviewDocTopicjsflag){TopicfocusTwo()}else{jQuery.getScript("/js/viewDocTopic.js",function(){TopicfocusTwo();loadviewDocTopicjsflag=true})}});$(".anonymityloginhref").click(function(){if(loadviewDocTopicjsflag){docvalidateTwo("1")}else{jQuery.getScript("/js/viewDocTopic.js",function(){docvalidateTwo("1");loadviewDocTopicjsflag=true})}});$(".anonymityregisthref").click(function(){if(loadviewDocTopicjsflag){docvalidateTwo("2")}else{jQuery.getScript("/js/viewDocTopic.js",function(){docvalidateTwo("2");loadviewDocTopicjsflag=true})}});$(".submitTopicBtn").click(function(){if(loadviewDocTopicjsflag){SubmitNewTwo()}else{jQuery.getScript("/js/viewDocTopic.js",function(){SubmitNewTwo();loadviewDocTopicjsflag=true})}});$(".perfectcordochref").click(function(){if(loadperfectcordocjsflag){perFectCorDoc($("#doctitle").val(),false)}else{jQuery.getScript("/js/perfectcordoc.js",function(){perFectCorDoc($("#doctitle").val(),false);loadperfectcordocjsflag=true})}});$(".doccontestbuyhref").click(function(){if(loaddoccontestjsflag){buy_docs(false,$("#doctitle").val())}else{jQuery.getScript("/js/doccontest.js",function(){buy_docs(false,$("#doctitle").val());loaddoccontestjsflag=true})}});$(".docconteststarthref").click(function(){if(loaddoccontestjsflag){contest_docs(false,$("#doctitle").val())}else{jQuery.getScript("/js/doccontest.js",function(){contest_docs(false,$("#doctitle").val());loaddoccontestjsflag=true})}});$("#recommend").click(function(){if(loadviewdocfunctionjsflag){doDig($("#doctitle").val())}else{jQuery.getScript("/js/viewdocfunction.js",function(){doDig($("#doctitle").val());loadviewdocfunctionjsflag=true})}});$("#renamehref").click(function(){if(loadviewdocfunctionjsflag){ShowDocRename()}else{jQuery.getScript("/js/viewdocfunction.js",function(){ShowDocRename();loadviewdocfunctionjsflag=true})}});$(".editsummaryhref").click(function(){if(loadviewdocfunctionjsflag){PopeditSummary()}else{jQuery.getScript("/js/viewdocfunction.js",function(){PopeditSummary();loadviewdocfunctionjsflag=true})}});$(".completetaghref").click(function(){if(loaddocTagjsflag){ifLock()}else{jQuery.getScript("/js/docTag.js",function(){ifLock();loaddocTagjsflag=true})}});$("#addFigure").click(function(){if(loadviewdocfunctionjsflag){addFigure()}else{jQuery.getScript("/js/viewdocfunction.js",function(){addFigure();loadviewdocfunctionjsflag=true})}});if($("#doccatalog_hide_show").length>0){$("#doccatalog_hide_show").click(function(){if(loaddoccatalogjsflag){hideDoccatalog();setEnlarge()}else{jQuery.getScript("/js/doccatalog.js",function(){hideDoccatalog();setEnlarge();loaddoccatalogjsflag=true})}})}if($(".thesauruscorrecthref").length>0){$(".thesauruscorrecthref").click(function(){newshowCorrectionDiv("2")})}if($(".docfavhref").length>0){$(".docfavhref").click(function(){if(loadviewdocfunctionjsflag){doc2fav($("#doctitle").val())}else{jQuery.getScript("/js/viewdocfunction.js",function(){doc2fav($("#doctitle").val());loadviewdocfunctionjsflag=true})}})}if($("#addDocInfoTempletbtn").length>0){$("#addDocInfoTempletbtn").click(function(){var a='<div id="information_module"><p class="tishi"><strong>数据读取中，请等待</strong></p><div id="templetInfoContent"></div></div>';setFloatWindow("为词条添加信息",a,500,false,false);$("#float_window").css("top",$("#float_window").offset().top-25);if(loaddocinfotempletjsflag){editdocinfotemplet()}else{jQuery.getScript("/js/docinfotemplet.js",function(){editdocinfotemplet();loaddocinfotempletjsflag=true})}})}setIframeHeight("dwhziframe");$(window).resize(function(){setEnlarge()});if($(".toggleshow").length>0&&$(".togglehide").length>0){$(".toggleshow").click(function(a){$(this).next().show();$(this).hide();$(this).parent().parent().find("#navData").show()});$(".togglehide").click(function(){$(this).prev().show();$(this).hide();$(this).parent().parent().find("#navData").hide()})}});newaddthesaurus=function(){if(loaddocThesaurusjsflag){thesaurusIfLock()}else{jQuery.getScript("/js/docThesaurus.js",function(){thesaurusIfLock();loaddocThesaurusjsflag=true})}};newshowCorrectionDiv=function(a){if(loadallcerrectionjsflag){showCorrectionDiv(a)}else{jQuery.getScript("/js/allcerrection.js",function(){showCorrectionDiv(a);loadallcerrectionjsflag=true})}};newsubmitCorrection=function(a){if(loadallcerrectionjsflag){submitCorrection(a)}else{jQuery.getScript("/js/allcerrection.js",function(){submitCorrection(a);loadallcerrectionjsflag=true})}};perfectinfotempletdata=function(a){var b='<div id="information_module"><p class="tishi"><strong>数据读取中，请等待</strong></p><div id="templetInfoContent"></div></div>';setFloatWindow("编辑信息",b,500,false,false);$("#float_window").css("top",$("#float_window").offset().top-30);if(loaddocinfotempletjsflag){editdocinfotemplet(a)}else{jQuery.getScript("/js/docinfotemplet.js",function(){editdocinfotemplet(a);loaddocinfotempletjsflag=true})}return false};var wikilinkno;var xmlHttp;var firstimgData;var firstimg;var headp;var dataDiv;var dataTable;var dataTableBody;var summary;var curX=0,curY=0;var gDivMoveFlag=false;var gDisplayFlag=false;var gUpdateFlag=true;var gDoctitle=null;var gCurWidth=0,gCurHeight=0;var gMouseOverFlag=false;var gMouseOutFlag=true;function send_request(a){xmlHttp=false;createXMLHttpRequest();xmlHttp.onreadystatechange=processRequest;xmlHttp.open("GET",a,true);xmlHttp.send(null)}function processlinks(){var a=document.links;var c=a.length;for(i=0;i<c;i++){var b=null;try{b=a[i].href;if(IE){cssName=a[i].getAttribute("className")}else{cssName=a[i].getAttribute("class")}if(cssName!="innerlink"){continue}}catch(d){continue}if(b!=null){if(b.indexOf("/wiki/")!=-1){wikilinkno="wikilink"+i;if(IE){a[i].onmouseover=handle_mouseover_IE;a[i].setAttribute("target","_blank");a[i].onmouseout=function(){setTimeout("closeDiv()",500);gUpdateFlag=true;gMouseOutFlag=true}}else{a[i].setAttribute("target","_blank");a[i].setAttribute("id",wikilinkno);a[i].onmouseover=handle_mouseover;a[i].onmouseout=function(){setTimeout("closeDiv()",500);gUpdateFlag=true;gMouseOutFlag=true}}}}}}function handle_mouseover_IE(){gMouseOutFlag=false;if(!gUpdateFlag){return}showDocSummary_IE(this);gUpdateFlag=false}function handle_mouseover(){gMouseOutFlag=false;if(!gUpdateFlag){return}showDocSummary();gUpdateFlag=false}function initVars(){if(document){dataTableBody=document.getElementById("summaryDataBody")}dataDiv=document.getElementById("popup");headp=document.getElementById("headp");if(dataDiv!=null){dataDiv.onmouseleave=onMouseLeave;dataDiv.onmousedown=onMouseDown;dataDiv.onmouseup=onMouseUp;dataDiv.onmouseover=onMouseOver;document.onmousemove=onMouseMove;processlinks()}}function onMouseOver(){gMouseOverFlag=true}function onMouseLeave(){gMouseOverFlag=false;if(gDisplayFlag||gDivMoveFlag||!gMouseOutFlag){return}clearData()}function closeDiv(){if(gDisplayFlag||gDivMoveFlag||gMouseOverFlag||!gMouseOutFlag){return}clearData()}function onMouseDown(){gDivMoveFlag=true;if(dataDiv.setCapture){dataDiv.setCapture()}if(IE==true){getCursor(event)}else{try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(a){}curX=event.pageX;curY=event.pageY}gCurWidth=curX-parseInt(dataDiv.style.left);gCurHeight=curY-parseInt(dataDiv.style.top);dataDiv.style.cursor="hand";document.onselectstart=new Function("event.returnValue=false")}function onMouseUp(){if(dataDiv.releaseCapture){dataDiv.releaseCapture()}gDivMoveFlag=false;dataDiv.style.cursor="default";document.onselectstart=new Function("event.returnValue=true");gMouseOutFlag=false;test=setInterval("hasLink()",20)}function hasLink(){var a=dataDiv.getElementsByTagName("a");for(var b=0;b<a.length;b++){a[b].onclick=function(){return true}}clearInterval(test)}function onMouseMove(){if(!gDivMoveFlag){return}var a=dataDiv.getElementsByTagName("a");for(var b=0;b<a.length;b++){a[b].onclick=function(){return false}}if(IE==true){getCursor(event)}else{try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(c){}curX=event.pageX;curY=event.pageY}dataDiv.style.left=(curX-gCurWidth)+"px";dataDiv.style.top=(curY-gCurHeight)+"px"}function showDocSummary(){try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(d){}curX=event.pageX;curY=event.pageY;var a=event.target;innerObj=a;var c=a.firstChild.data;if(0==c.Trim().length){return}while(a.nodeName.toUpperCase()!="A"){a=a.parentNode}createXMLHttpRequest();var c=a.innerText;gDoctitle=c;var b="/validateDocSummary.do?doc_title="+encodeURI(c);xmlHttp.open("GET",b,true);xmlHttp.onreadystatechange=callback;xmlHttp.send(null)}function window_prototype_get_event(){var b=arguments.callee.caller;var a;while(b!=null){a=b.arguments[0];if(a&&(a.constructor==Event||a.constructor==MouseEvent)){return a}b=b.caller}return null}function showDocSummary_IE(c,d){getCursor(d);innerObj=c;createXMLHttpRequest();if(c.childNodes.length>1){var e;docTitle="";for(var b=0;b<c.childNodes.length;b++){e=c.childNodes[b];if(e.nodeType==3){docTitle=c.childNodes[b].toString();break}}}else{docTitle=c.innerText}if(docTitle==gDoctitle&&dataDiv.style.visibility=="visible"){return}gDoctitle=docTitle;var a="/validateDocSummary.do?doc_title="+encodeURI(gDoctitle);xmlHttp.open("GET",a,true);xmlHttp.onreadystatechange=callback;xmlHttp.send(null)}function callback(){if(xmlHttp.readyState==4){if(xmlHttp.status==200){try{setData(xmlHttp.responseXML);var a=dataDiv.getElementsByTagName("a");for(var b=0;b<a.length;b++){a[b].onmousedown=function(){return false}}}catch(c){}}}}function setData(h){var a=dataTableBody.childNodes.length;for(var b=a-1;b>=0;b--){dataTableBody.removeChild(dataTableBody.childNodes[b])}dataDiv.style.visibility="visible";var f=xmlHttp.responseXML.getElementsByTagName("flag")[0].firstChild.data;var c=xmlHttp.responseXML.getElementsByTagName("doctitle")[0].firstChild.data;var k=xmlHttp.responseXML.getElementsByTagName("docid")[0].firstChild.data;summary=xmlHttp.responseXML.getElementsByTagName("summary")[0].firstChild.data;firstimg=xmlHttp.responseXML.getElementsByTagName("firstimg")[0].firstChild==null?"null":xmlHttp.responseXML.getElementsByTagName("firstimg")[0].firstChild.data;var e="";var d="";var g="";closeData=constructHead();headp.innerHTML=closeData;if(f=="false"){setOffsets();e='<tr><td width="300" bgcolor="#F9F7F7" align="center"><br><br><a href="/createDocAuth.do?doc_title='+encodeURI(gDoctitle)+"\"><font size='2' color='red' >词条不存在,请点击创建!</font></a><br><br><br></td></tr>";dataTableBody.innerHTML='<p style="padding:5px; margin:0;"><a href="/createDocAuth.do?doc_title='+encodeURI(gDoctitle)+"\"><font size='2' color='red' >词条不存在,请点击创建!</font></a></p>"}if(f=="true"){setOffsets();if(firstimg!="null"){g=constructIamge(firstimg)}d=g+constructSummary(summary);dataTableBody.innerHTML=d}}function constructHead(){var c="";var a=(gDoctitle.length>10)?(gDoctitle.substring(0,10)+"..."):gDoctitle;var b=(gDisplayFlag==true)?"/images/momo/tudinged_normal.gif":"/images/momo/tuding_normal.gif";if(IE){c='<span style="float:left; font-size:12px; margin-left:5px;"><img src="/images/momo/momo_3.gif" align="absmiddle" /><a href="http://www.hudong.com/wiki/'+encodeURI(gDoctitle)+'"target="_blank" style=" color:#FF0000; text-decoration: none;">'+a+'</a></span><span style="float:right; margin-right:5px;"><img src="/images/momo/guanbi_normal.gif" border="0"onmouseover="changImgcloseStatus_IE(this)" onmouseout="changImgcloseStatus_IE(this)" onclick="clearData()" width="14" height="14" /></span>'}else{c='<span style="float:left; font-size:12px; margin-left:5px;"><img src="/images/momo/momo_3.gif" align="absmiddle" /><a href="http://www.hudong.com/wiki/'+encodeURI(gDoctitle)+'"target="_blank" style=" color:#FF0000; text-decoration: none;">'+a+'</a></span><span style="float:right; margin-right:5px;"><img src="/images/momo/guanbi_normal.gif" border="0" onmouseover="changImgcloseStatus()" onmouseout="changImgcloseStatus()" onclick="clearData()" width="14" height="14" /></span>'}return c}function constructIamge(a){if(a!="null"){firstimgData='<a href="http://www.hudong.com/wiki/'+encodeURI(gDoctitle)+'" target="_blank"><img src="'+a+'" style="margin:5px 10px 0 5px; float:left; border:1px solid #ccc; padding:1px" /></a>'}return firstimgData}function constructSummary(b){var a="";if(b=="null"){a='<p style="padding:5px; margin:0;">摘要：无</p>'}else{a='<p style="padding:5px; margin:0;">'+b+'<a style="padding-left:5px;" href="http://www.hudong.com/wiki/'+encodeURI(gDoctitle)+'" target="_blank">查看详情&gt;&gt;</a></p>'}return a}function constructContent(d,c){var b='<tr><td colspan="8" valign="top" background="/images/momo/momobg.gif"><table width="98%" border="0" align="center" cellpadding="0" cellspacing="0"><tr><td height="3"></td></tr><tr><td><table class="biankuangmomo" width="100%" border="0" cellpadding="0" cellspacing="0">';var a='<tr><td height="4" colspan="2" bgcolor="#F9F7F7"></td></tr></table></td></tr><tr><td height="2"></td></tr></table></td>';return b+d+c+a}function createRow(d){var c,a,b;c=document.createElement("tr");a=document.createElement("td");a.innerHTML=d;c.appendChild(a);return c}function setOffsets(){if(gDisplayFlag){return}curX=innerObj.offsetLeft;if(summary.length>30&&firstimg!="null"){switch(biggestArea()){case 0:dataDiv.style.left=(curX-300)+"px";dataDiv.style.top=curY-202+"px";break;case 1:dataDiv.style.left=(curX+120)+"px";dataDiv.style.top=curY-202+"px";break;case 2:dataDiv.style.left=(curX-320)+"px";dataDiv.style.top=curY-5+"px";break;case 3:dataDiv.style.left=(curX+100)+"px";dataDiv.style.top=curY-5+"px";break}}else{if(summary.length>30&&firstimg=="null"){switch(biggestArea()){case 0:dataDiv.style.left=(curX-300)+"px";dataDiv.style.top=curY-165+"px";break;case 1:dataDiv.style.left=(curX+120)+"px";dataDiv.style.top=curY-155+"px";break;case 2:dataDiv.style.left=(curX-320)+"px";dataDiv.style.top=curY-5+"px";break;case 3:dataDiv.style.left=(curX+100)+"px";dataDiv.style.top=curY-5+"px";break}}else{switch(biggestArea()){case 0:dataDiv.style.left=(curX-300)+"px";dataDiv.style.top=curY-84+"px";break;case 1:dataDiv.style.left=(curX+120)+"px";dataDiv.style.top=curY-88+"px";break;case 2:dataDiv.style.left=(curX-300)+"px";dataDiv.style.top=curY-5+"px";break;case 3:dataDiv.style.left=(curX+100)+"px";dataDiv.style.top=curY-5+"px";break}}}}function clearData(){var b=dataTableBody.childNodes.length;for(var a=b-1;a>=0;a--){dataTableBody.removeChild(dataTableBody.childNodes[a])}dataDiv.style.visibility="hidden";gDisplayFlag=false}function changImgcloseStatus_IE(a){var c=a.src;var b=c.substring(0,c.lastIndexOf("/")+1);if(c.substring(c.lastIndexOf("/")+1,c.length)=="guanbi_normal.gif"){a.src=b+"guanbi_over.gif"}else{a.src=b+"guanbi_normal.gif"}}function changImgholdStatus_IE(a){var c=a.src;var b=c.substring(0,c.lastIndexOf("_")+1);if(c.substring(c.lastIndexOf("_")+1,c.length)=="normal.gif"){a.src=b+"over.gif"}else{a.src=b+"normal.gif"}}function changImgholdType_IE(a){gDisplayFlag=(gDisplayFlag==true)?false:true;var d=a.src;var c=d.substring(0,d.lastIndexOf("/")+1);var b=d.substring(d.lastIndexOf("/")+1,d.length);if(b=="tudinged_over.gif"){a.src=c+"tuding_over.gif"}else{a.src=c+"tudinged_over.gif"}}function changImgcloseStatus(){try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(d){}var a=event.target;var c=a.src;var b=c.substring(0,c.lastIndexOf("/")+1);if(c.substring(c.lastIndexOf("/")+1,c.length)=="guanbi_normal.gif"){a.src=b+"guanbi_over.gif"}else{a.src=b+"guanbi_normal.gif"}}function changImgholdStatus(){try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(d){}var a=event.target;var c=a.src;var b=c.substring(0,c.lastIndexOf("_")+1);if(c.substring(c.lastIndexOf("_")+1,c.length)=="normal.gif"){a.src=b+"over.gif"}else{a.src=b+"normal.gif"}}function changImgholdType(){gDisplayFlag=(gDisplayFlag==true)?false:true;try{window.constructor.prototype.__defineGetter__("event",window_prototype_get_event)}catch(f){}var a=event.target;var d=a.src;var c=d.substring(0,d.lastIndexOf("/")+1);var b=d.substring(d.lastIndexOf("/")+1,d.length);if(b=="tudinged_over.gif"){a.src=c+"tuding_over.gif"}else{a.src=c+"tudinged_over.gif"}}function biggestArea(){var g=curY-document.documentElement.scrollTop;var c=curX-document.documentElement.scrollLeft;var b=document.documentElement.clientHeight;var f=document.documentElement.clientWidth;var a=f-c;var h=b-g;var d=[g*c,g*a,h*c,h*a];var k=d[0];var l=0;for(var e=1;e<d.length;e++){if(k>=d[e]){continue}else{k=d[e];l=e}}return l}if(window.Event){Event.prototype.__defineSetter__("returnValue",function(a){if(!a){this.preventDefault()}return a});Event.prototype.__defineSetter__("cancelBubble",function(a){if(a){this.stopPropagation()}return a});Event.prototype.__defineGetter__("srcElement",function(){var a=this.target;while(a&&a.nodeType!=1){a=a.parentNode}return a});Event.prototype.__defineGetter__("fromElement",function(){var a;if(this.type=="mouseover"){a=this.relatedTarget}else{if(this.type=="mouseout"){a=this.target}}if(!a){return}try{while(a&&a.nodeType!=1){a=a.parentNode}}catch(b){}return a});Event.prototype.__defineGetter__("toElement",function(){var a;if(this.type=="mouseout"){a=this.relatedTarget}else{if(this.type=="mouseover"){a=this.target}}if(!a){return}while(a&&a.nodeType!=1){a=a.parentNode}return a});Event.prototype.__defineGetter__("offsetX",function(){return this.layerX});Event.prototype.__defineGetter__("offsetY",function(){return this.layerY})}if(window.Document){}if(window.Node){Node.prototype.replaceNode=function(a){this.parentNode.replaceChild(a,this)};Node.prototype.removeNode=function(b){if(b){return this.parentNode.removeChild(this)}else{var a=document.createRange();a.selectNodeContents(this);return this.parentNode.replaceChild(a.extractContents(),this)}};Node.prototype.swapNode=function(b){var c=this.nextSibling;var a=this.parentNode;node.parentNode.replaceChild(this,b);a.insertBefore(node,c)}}if(window.HTMLElement){HTMLElement.prototype.__defineGetter__("all",function(){var b=this.getElementsByTagName("*");var c=this;b.tags=function(a){return c.getElementsByTagName(a)};return b});HTMLElement.prototype.__defineGetter__("parentElement",function(){if(this.parentNode==this.ownerDocument){return null}return this.parentNode});HTMLElement.prototype.__defineGetter__("children",function(){var c=[];var a=0;var d;for(var b=0;b<this.childNodes.length;b++){d=this.childNodes[b];if(d.nodeType==1){c[a++]=d;if(d.name){if(!c[d.name]){c[d.name]=[]}c[d.name][c[d.name].length]=d}if(d.id){c[d.id]=d}}}return c});HTMLElement.prototype.__defineGetter__("currentStyle",function(){return this.ownerDocument.defaultView.getComputedStyle(this,null)});HTMLElement.prototype.__defineSetter__("outerHTML",function(b){var a=this.ownerDocument.createRange();a.setStartBefore(this);var c=a.createContextualFragment(b);this.parentNode.replaceChild(c,this);return b});HTMLElement.prototype.__defineGetter__("outerHTML",function(){var a;var b=this.attributes;var d="<"+this.tagName;for(var c=0;c<b.length;c++){a=b[c];if(a.specified){d+=" "+a.name+'="'+a.value+'"'}}if(!this.canHaveChildren){return d+">"}return d+">"+this.innerHTML+"</"+this.tagName+">"});HTMLElement.prototype.__defineGetter__("canHaveChildren",function(){switch(this.tagName.toLowerCase()){case"area":case"base":case"basefont":case"col":case"frame":case"hr":case"img":case"br":case"input":case"isindex":case"link":case"meta":case"param":return false}return true});HTMLElement.prototype.__defineSetter__("innerText",function(b){var a=document.createTextNode(b);this.innerHTML=a;return a});HTMLElement.prototype.__defineGetter__("innerText",function(){var a=this.ownerDocument.createRange();a.selectNodeContents(this);return a.toString()});HTMLElement.prototype.__defineSetter__("outerText",function(b){var a=document.createTextNode(b);this.outerHTML=a;return a});HTMLElement.prototype.__defineGetter__("outerText",function(){var a=this.ownerDocument.createRange();a.selectNodeContents(this);return a.toString()});HTMLElement.prototype.attachEvent=function(c,b){var a=c.replace(/on/,"");b._ieEmuEventHandler=function(d){window.event=d;return b()};this.addEventListener(a,b._ieEmuEventHandler,false)};HTMLElement.prototype.detachEvent=function(c,b){var a=c.replace(/on/,"");if(typeof(b._ieEmuEventHandler)=="function"){this.removeEventListener(a,b._ieEmuEventHandler,false)}else{this.removeEventListener(a,b,true)}};HTMLElement.prototype.contains=function(a){do{if(a==this){return true}}while(a=a.parentNode);return false};HTMLElement.prototype.insertAdjacentElement=function(a,b){switch(a){case"beforeBegin":this.parentNode.insertBefore(b,this);break;case"afterBegin":this.insertBefore(b,this.firstChild);break;case"beforeEnd":this.appendChild(b);break;case"afterEnd":if(this.nextSibling){this.parentNode.insertBefore(b,this.nextSibling)}else{this.parentNode.appendChild(b)}break}};HTMLElement.prototype.insertAdjacentHTML=function(b,d){var c=this.ownerDocument.createRange();c.setStartBefore(this);var a=c.createContextualFragment(d);this.insertAdjacentElement(b,a)};HTMLElement.prototype.insertAdjacentText=function(b,c){var a=document.createTextNode(c);this.insertAdjacentElement(b,a)};HTMLElement.prototype.attachEvent=function(c,b){var a=c.replace(/on/,"");b._ieEmuEventHandler=function(d){window.event=d;return b()};this.addEventListener(a,b._ieEmuEventHandler,false)};HTMLElement.prototype.detachEvent=function(c,b){var a=c.replace(/on/,"");if(typeof(b._ieEmuEventHandler)=="function"){this.removeEventListener(a,b._ieEmuEventHandler,false)}else{this.removeEventListener(a,b,true)}}}var staticXMLhttp;function getdocinfo(){if(document.getElementById("thslinkwz").getElementsByTagName("a").length>0){document.getElementById("thslinkwz").style.display="block"}staticXMLhttp=createXMLHttpRequestByObject(staticXMLhttp);var c=document.getElementById("doc_title").value;var d=document.getElementById("docid").value;var a=document.getElementById("dociden").value;var e="/getdocinfo.do?docid="+d+"&dociden="+a+"&doctitle="+encodeURI(c);if(getHdCookie(hdCookieName)==null){var b=document.getElementById("anonymity");if(b!=null){document.getElementById("anonymity").style.display="block"}}if(document.getElementById("championiden")!=null){e=e+"&championiden="+document.getElementById("championiden").value}if(document.getElementById("lateeditiden")!=null){e=e+"&lateeditiden="+document.getElementById("lateeditiden").value}staticXMLhttp.open("POST",e,true);staticXMLhttp.onreadystatechange=callback_getdocinfo;staticXMLhttp.send(null)}function callback_getdocinfo(){if(staticXMLhttp.readyState==4){if(staticXMLhttp.status==200){var J=staticXMLhttp.responseXML.getElementsByTagName("statinfo")[0].firstChild;document.getElementById("PIECE_INDEX_HEAD_STA").innerHTML=J.data;var Y=staticXMLhttp.responseXML.getElementsByTagName("loginstate")[0];if(Y!=null){var V=Y.getElementsByTagName("expertstate")[0].firstChild.data;var M=Y.getElementsByTagName("networkerstate")[0].firstChild.data;var x=Y.getElementsByTagName("adminstate")[0].firstChild.data;var Z=Y.getElementsByTagName("thesureEditor")[0].firstChild.data;var E=Y.getElementsByTagName("editthesure")[0].firstChild.data;var L=Y.getElementsByTagName("editambigahth")[0].firstChild.data;if(V=="1"||M=="1"||Z=="1"||E=="1"){var p=document.getElementById("show_thesaurus_dt");p.innerHTML=p.innerHTML+'<a id="addthesaurus" href="javascript:newaddthesaurus();" class="r">我来补充</a>';document.getElementById("show_thesaurus").style.display="block"}if(x=="1"||L=="1"){if(document.getElementById("renamehref")!=null){document.getElementById("renamehref").style.display=""}}if(document.getElementById("_loginstate")!=null){document.getElementById("_loginstate").value="1"}var R=Y.getElementsByTagName("editDocInfoTempletth")==null?null:Y.getElementsByTagName("editDocInfoTempletth")[0]==null?null:Y.getElementsByTagName("editDocInfoTempletth")[0].firstChild==null?null:Y.getElementsByTagName("editDocInfoTempletth")[0].firstChild.data;if(R!=null&&R=="true"){if($(".perfectinfotempletdatatr").length>0){$(".perfectinfotempletdatatr").show()}if($("#addDocInfoTempletdiv").length>0){$("#addDocInfoTempletdiv").show()}}}var al=document.getElementById("editlock");var ah=document.getElementById("editlockdl");if(al!=null&&ah!=null){var Q=staticXMLhttp.responseXML.getElementsByTagName("editlock")[0];if(Q!=null){var t="<li>此词条正在被";var o=Q.getElementsByTagName("state")[0].firstChild.data;var N=Q.getElementsByTagName("userid")[0].firstChild.data;if(Q.getElementsByTagName("userip")[0]!=null){var H=Q.getElementsByTagName("userip")[0].firstChild.data}var O=Q.getElementsByTagName("useriden")[0].firstChild.data;var T=Q.getElementsByTagName("usernick")[0].firstChild.data;if(N=="0"){t=t+"匿名用户("+H+")锁定编辑中!"}else{t=t+"<a href='http://wiki.hudong.com/u/"+O+"/index'>"+T+"</a>锁定编辑中!</li>"}ah.innerHTML=ah.innerHTML.Trim()+t;al.style.display=""}else{var q=staticXMLhttp.responseXML.getElementsByTagName("overTwoLocks")[0];if(q!=null){al.style.display="";ah.innerHTML=ah.innerHTML.Trim()+"<li>您已经锁定了两个以上的词条，所以您不能够继续编辑该词条</li>"}}if(ah!=null){if(ah.innerHTML.Trim()==""){al.parentNode.removeChild(al)}else{al.style.display=""}}}document.getElementById("viewnum").innerHTML="共被浏览大约 "+staticXMLhttp.responseXML.getElementsByTagName("viewnum")[0].firstChild.data+" 次";var u=staticXMLhttp.responseXML.getElementsByTagName("cordocimg")[0];var U=0;if(u!=null){var S=document.getElementsByName("corimg");U=S.length;for(var ac=0;ac<S.length;ac++){if(u.getElementsByTagName("img")[ac]!=null){S[ac].src=u.getElementsByTagName("img")[ac].firstChild.data}}}var K=staticXMLhttp.responseXML.getElementsByTagName("champion")[0];if(K!=null){var n=document.getElementById("championimg");if(K.getElementsByTagName("portrait")[0].firstChild!=null){n.src=K.getElementsByTagName("portrait")[0].firstChild.data}else{n.src="/images/tou.gif"}if(K.getElementsByTagName("titleimghelp")[0].firstChild!=null&&K.getElementsByTagName("titleimg")[0].firstChild!=null){var X=document.getElementById("chamtitleimghelp");X.href=K.getElementsByTagName("titleimghelp")[0].firstChild.data;X.innerHTML="<img title='"+K.getElementsByTagName("titleimgtag")[0].firstChild.data+"' src='"+K.getElementsByTagName("titleimg")[0].firstChild.data+"' id='chamtitleimg' class='l v_middle'/>"}else{document.getElementById("chamtitleimghelp").parentNode.removeChild(document.getElementById("chamtitleimghelp"))}}var G=staticXMLhttp.responseXML.getElementsByTagName("lateedit")[0];if(G!=null){var r=document.getElementById("lateimg");if(G.getElementsByTagName("portrait")[0].firstChild!=null){r.src=G.getElementsByTagName("portrait")[0].firstChild.data}else{r.src="/images/tou.gif"}if(G.getElementsByTagName("titleimghelp")[0].firstChild!=null&&G.getElementsByTagName("titleimg")[0].firstChild!=null){var I=document.getElementById("latetitleimghelp");I.href=G.getElementsByTagName("titleimghelp")[0].firstChild.data;I.innerHTML="<img title='"+G.getElementsByTagName("titleimgtag")[0].firstChild.data+"' src='"+G.getElementsByTagName("titleimg")[0].firstChild.data+"' id='latetitleimg' class='l v_middle'/>"}else{document.getElementById("latetitleimghelp").parentNode.removeChild(document.getElementById("latetitleimghelp"))}}var c="";if(Y==null){document.getElementById("_doc_flag").value="/wiki/"+document.getElementById("doctitle_utf8").value;if(document.getElementById("topic_email_li")!=null){document.getElementById("topic_email_li").style.display="block"}if(document.getElementById("topic_pwd_li")!=null){document.getElementById("topic_pwd_li").style.display="block"}}else{}var am=staticXMLhttp.responseXML.getElementsByTagName("TopicNum")[0].firstChild;if(am!=null){var g=document.getElementById("topichref");if(g!=null){if(am.data!="0"){g.innerHTML="我要评论（"+am.data+"条）&gt;&gt"}else{g.innerHTML="我要评论&gt;&gt"}}}var m=staticXMLhttp.responseXML.getElementsByTagName("TotalTopicNum")[0].firstChild;if(m!=null){var af=document.getElementById("totalTopicNum");if(af!=null){if(m.data!=0){af.innerHTML="讨论区("+m.data+"条)"}else{af.innerHTML="讨论区"}}var a=document.getElementById("editImage")==null?null:document.getElementById("editImage").parentNode.getElementsByTagName("a");var P=null;if(a!=null){P=a[2]}if(P!=null){if(m.data!=0){P.innerHTML="参与讨论("+m.data+"条)"}else{P.innerHTML="参与讨论"}}}if(am!=null&&am.data!="0"){var s="";var ad=document.getElementById("topictable");if(ad!=null){document.getElementById("topictable").style.display=""}var w=staticXMLhttp.responseXML.getElementsByTagName("Record_TopicList")[0];if(w!=null){var C=w.getElementsByTagName("TopicList");if(C!=null&&C.length>0){var ae=null,A,z,B,ab;var W,v,F,D,b,b;var k,ag;var y,l,h,f,e,d;var ai=document.getElementById("topiclisttbody");if(ai!=null){for(ac=0,j=0;ac<C.length;ac++,j++){ae=C[ac];A=ae.getElementsByTagName("TOPIC_TITLE")[0].firstChild.data;z=ae.getElementsByTagName("USER_NICK")[0].firstChild.data;B=ae.getElementsByTagName("LAST_POST_TIME")[0].firstChild.data;ab=ae.getElementsByTagName("LAST_POST_USER_NICK")[0].firstChild.data;W=ae.getElementsByTagName("LAST_POST_USER_IP")[0].firstChild.data;v=ae.getElementsByTagName("USER_IP")[0].firstChild.data;F=ae.getElementsByTagName("USER_ID")[0].firstChild.data;D=ae.getElementsByTagName("USER_ID_ENCRYPT")[0].firstChild.data;b=ae.getElementsByTagName("DOC_TOPICS_ID_ENCRYPT")[0].firstChild.data;k=ae.getElementsByTagName("LAST_POST_USER_ID_ENCRYPT")[0].firstChild.data;ag=ae.getElementsByTagName("LAST_POST_USER_ID")[0].firstChild.data;y=ai.insertRow(j);l=y.insertCell(0);l.innerHTML="<a href='http://wikibar.hudong.com/posts/"+b+"' target='_blank'>"+A+"</a>";h=y.insertCell(1);if(F!=null&&F!="0"){h.innerHTML="<a href='http://wiki.hudong.com/u/"+D+"/index' target='_blank'>"+z+"</a>"}else{h.innerHTML=v}f=y.insertCell(2);f.innerHTML=B;e=y.insertCell(3);if(ag!=null&&ag!="0"){e.innerHTML="<a href='http://wiki.hudong.com/u/"+k+"/index' target='_blank'>"+ab+"</a>"}else{e.innerHTML=W}}}}}}var ak=document.getElementById("recommend");if(ak!=null){var aj=document.getElementById("recommendnum");if(aj!=null){var aa=staticXMLhttp.responseXML.getElementsByTagName("RecommendNum")[0].firstChild;aj.innerHTML=aa.data}}setEnlarge();if($("#text_right").height()>$("#text_left").height()){setTimeout(function(){$("#text_left").height($("#text_right").height()+U*15)},1000)}else{}}}};