var OspodLanguage=new Object();OspodLanguage.AvailableLanguages={'de':'German','en':'English','en-au':'English (Australia)','en-ca':'English (Canadian)','en-uk':'English (United Kingdom)','es':'Spanish','fr':'French','it':'Italian','ja':'Japanese','ko':'Korean','ru':'Russian','th':'Thai','zh':'Chinese Traditional','zh-cn':'Chinese Simplified'};OspodLanguage.DefaultLanguage="zh-cn";OspodLanguage.GetActiveLanguage=function(){var sUserLang;var localeCookie="_cmsLocale";var arr=document.cookie.match(new RegExp("(^| )"+localeCookie+"=([^;]*)(;|$)"));if(arr!=null){sUserLang=unescape(arr[2]);};if(sUserLang!=null&&sUserLang!=""){if(sUserLang.length>2){var re=/_/;sUserLang=sUserLang.replace(re,"-");};return sUserLang.toLowerCase();};if(navigator.userLanguage)sUserLang=navigator.userLanguage.toLowerCase();else if(navigator.language)sUserLang=navigator.language.toLowerCase();else{return this.DefaultLanguage;};if(sUserLang.length>=5){sUserLang=sUserLang.substr(0,5);if(this.AvailableLanguages[sUserLang])return sUserLang;};if(sUserLang.length>=2){sUserLang=sUserLang.substr(0,2);if(this.AvailableLanguages[sUserLang])return sUserLang;};return this.DefaultLanguage;};OspodLanguage.LoadLanguage=function(url){document.write('<script type="text/javascript" src="'+url+'" charset="utf-8"><\/script>');};OspodLanguage.languageCheck=function(){try{I18n.language;}catch(err){if(ospodLang!=null&&ospodLang.length>2){OspodLanguage.LoadLanguage(_tplResAddr+"message_"+ospodLang.substr(0,2)+".js?"+_resPatch);}}};var _isServerRes=false;var _resSvrAddr;var _tplResAddr=_templatePath+"lib/";var _resPatch=0;OspodLanguage.initResParam=function(){var _scripts=document.getElementsByTagName("script");var _matchRE=/(http\:\/\/resource\.ospod\.com\/.+\/).*\/ospodcommon\.js\?(.*)/ig;var scriptSrc;for(var i=0;i<_scripts.length;i++){scriptSrc=_scripts[i].src;if(scriptSrc&&scriptSrc.match(_matchRE)){_isServerRes=true;_resSvrAddr=RegExp.$1;_tplResAddr=_resSvrAddr+"tpl/";_resPatch=RegExp.$2;break;}};if(!_isServerRes&&scriptSrc.match(/.+\/ospodcommon\.js\?(.*)$/ig)){_resPatch=RegExp.$1;}};var ospodLang=OspodLanguage.GetActiveLanguage();try{OspodLanguage.initResParam();OspodLanguage.LoadLanguage(_tplResAddr+"message_"+ospodLang+".js?"+_resPatch);OspodLanguage.languageCheck();}catch(err){};function $(element){var e=("string"==typeof(element))?document.getElementById(element):element;if(e&&e.tagName&&e.tagName.toLowerCase()=="form"){for(var m in Form.Methods){e[m]=Form.Methods[m];}};return e;};function $N(name){return document.getElementsByName(name);};var $A=function(iterable){if(!iterable)return[];if(iterable.toArray){return iterable.toArray();}else{var results=[];for(var i=0,length=iterable.length;i<length;i++)results.push(iterable[i]);return results;}};Function.prototype.bind=function(){var __method=this,args=$A(arguments),object=args.shift();return function(){return __method.apply(object,args.concat($A(arguments)));}};function doZoom(num){var obj=$("zoom");obj.style.fontSize=num+"px";obj.style.lineHeight=num*2+"px";};function closeMe(){window.close();};function Browser(){var ua,s,i;this.isIE=false;this.isIE7=false;this.isIE8=false;this.isOP=false;this.isNS=false;this.version=null;ua=navigator.userAgent;s="Opera";if((i=ua.indexOf(s))>=0){this.isOP=true;this.version=parseFloat(ua.substr(i+s.length));return;};s="Netscape6/";if((i=ua.indexOf(s))>=0){this.isNS=true;this.version=parseFloat(ua.substr(i+s.length));return;};s="Gecko";if((i=ua.indexOf(s))>=0){this.isNS=true;this.version=6.1;return;};s="MSIE";if((i=ua.indexOf(s))){this.version=parseFloat(ua.substr(i+s.length));if(this.version==8){this.isIE8=true;}else if(this.version==7){this.isIE7=true;};this.isIE=true;return;}};var browser=new Browser();function doPagePrint(obj){window.print();};function getWindowEvent(){if(browser.isIE){return window.event;}else{var o=arguments.callee.caller;var e;while(o!=null){e=o.arguments[0];if(e&&(e.constructor==Event||e.constructor==MouseEvent)){return e;};o=o.caller;};return null;}};function getEventSrcElement(){var event=getWindowEvent();if(event!=null){var e=event.target||event.srcElement;return e;};return null;};function getRequestCookie(name){return getCookie(name);};function setCookie(name,value,duration){var Days=duration?duration:30;var exp=new Date();exp.setTime(exp.getTime()+Days*24*60*60*1000);document.cookie=name+"="+escape(value)+";expires="+exp.toGMTString();};function getCookie(name){var arr=document.cookie.match(new RegExp("(^| )"+name+"=([^;]*)(;|$)"));if(arr!=null)return unescape(arr[2]);return null;};function delCookie(name){var exp=new Date();exp.setTime(exp.getTime()-1);var cval=getCookie(name);if(cval!=null)document.cookie=name+"="+cval+";expires="+exp.toGMTString();};var __keyDown=false;function keyLimit(event){if(!event){event=getWindowEvent();};var keyCode=event.keyCode?event.keyCode:(event.which?event.which:event.charCode);if((keyCode==116)||(event.ctrlKey&&keyCode==82)){var l=getCookie("_cmsf5");if(cookieEnable()&&!l&&!__keyDown&&!_forbidF5){__keyDown=true;var exp=new Date();exp.setTime(exp.getTime()+3*1000);document.cookie="_cmsf5=anything;expires="+exp.toGMTString();}else{__keyDown=true;if(document.addEventListener){event.preventDefault();}else{event.keyCode=0;};event.returnValue=false;}}};function keyRelease(event){__keyDown=false;};function cookieEnable(){var result=false;if(navigator.cookiesEnabled)return true;var cookieStr="testcookie=yes";document.cookie=cookieStr;var cookieSet=document.cookie;if(cookieSet.indexOf(cookieStr)>-1){result=true;};var date=new Date();date.setTime(date.getTime()-1000);document.cookie=cookieStr+"; expires="+date.toGMTString();return result;};if(window.event)document.captureEvents(Event.MOUSEUP);function forbidContextMenu(event){if(document.addEventListener){if(event.button==2||event.button==3){event.preventDefault();event.returnValue=false;}}else{if(event.button==2||event.button==3){event.keyCode=0;event.button=0;event.cancelBubble=true;event.returnValue=false;}}};function forbidCopy(event){if(document.addEventListener){event.preventDefault();event.returnValue=false;}else{event.keyCode=0;event.cancelBubble=true;event.returnValue=false;};return false;};function forbid(){if(window.addEventListener){document.addEventListener("keydown",keyLimit,false);document.addEventListener("keyup",keyRelease,false);if(_forbidContextMenu){document.addEventListener("contextmenu",forbidContextMenu,false);};if(_forbidCopy){document.addEventListener("selectstart",forbidCopy,false);document.addEventListener("copy",forbidCopy,false);}}else{document.attachEvent("onkeydown",keyLimit);document.attachEvent("onkeyup",keyRelease);if(_forbidContextMenu){document.attachEvent("oncontextmenu",function(){return false;});};if(_forbidCopy){document.attachEvent("onselectstart",function(){return false;});document.attachEvent("oncopy",forbidCopy);}}};try{forbid();}catch(e){};function doCommentSubmit(id){var content=$N("comment.content")[0].value;if(content==null||content==""){alert(I18n.commentContentEmpty);return;};var title=$N("comment.title")[0];if(title.value==null||title.value==""){title.value=I18n.commentDefaultTitle;};var url=_contextPath+"/cfn?cmsfn=0101&ID="+id;new Ajax.Request(url,{method:'post',parameters:$('commentForm').serialize(false),onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var root_node=root.getElementsByTagName('status')[0];var status=root_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){if(msg=="NULL")msg=I18n.commentSuccess;else msg=I18n.commentSuccess+"<br><br>"+msg;request.set("nc","true");var nowLocation=request.getUrl();_error_msg_show(msg,"window.location='"+nowLocation+"'",5,"");}else{if(msg=="NULL")msg=I18n.commentFailure;else msg=I18n.commentFailure+"<br><br>"+msg;_error_msg_show(msg,"",3,"");}}});};function doSupport(id){doCommentValueSubmit("0102",id);};function doDisagree(id){doCommentValueSubmit("0103",id);};function doNoCare(id){doCommentValueSubmit("0104",id);};function doCommentValueSubmit(fn,id){var url=_contextPath+"/cfn?cmsfn="+fn+"&umID="+id;new Ajax.Request(url,{method:'get',onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var root_node=root.getElementsByTagName('status')[0];var status=root_node.firstChild.data;if(status=="0"){_error_msg_show(I18n.commentValueSuccess,"windowReload()",5,"");}else{_error_msg_show(I18n.commentValueFailure,"",3,"");}}});};function windowReload(){request.set("nc","true");var nowLocation=request.getUrl();window.location=nowLocation;};function doSearchSubmit(id){if(!id){id="searchForm";};var form=document.forms[id];var keyword=$(form)["search.keyword"].value;if(keyword==null||keyword.replace(/(^\s*)|(\s*$)/g,"")==""){alert(I18n.searchKeywordEmpty);return;};form.action=_contextPath+"/cc?url=_search"+"&nc=true";form.method="post";var e=getEventSrcElement();if(e.tagName.toLowerCase()=="input"&&(e.type=="image"||e.type=="submit")){}else{form.submit();}};function doAdvancedSearchSubmit(id){if(!id){id="searchForm";};var form=document.forms[id];var keyword=$(form)["search.keyword"].value;if(keyword==null||keyword.replace(/(^\s*)|(\s*$)/g,"")==""){alert(I18n.searchKeywordEmpty);return;};form.action=_contextPath+"/search.php";form.method="post";var e=getEventSrcElement();if(e.tagName.toLowerCase()=="input"&&(e.type=="image"||e.type=="submit")){}else{form.submit();}};function doBoardSubmit(id){if(isNullValue("board.content",I18n.boardContentEmpty))return;if(isNullValue("board.title",I18n.boardTitleEmpty))return;var formValueStr="boardID="+id;var url=_contextPath+"/cfn?cmsfn=0201&"+formValueStr;new Ajax.Request(url,{method:'post',parameters:$($N('commentForm')[0]).serialize(false),onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){if(msg=="NULL")msg=I18n.boardCommitSuccess;else msg=I18n.boardCommitSuccess+"<br><br>"+msg;request.set("nc","true");var nowLocation=request.getUrl();_error_msg_show(msg,"window.location='"+nowLocation+"'",5,"");}else{if(msg=="NULL")msg=I18n.boardCommitFailure;else msg=I18n.boardCommitFailure+"<br><br>"+msg;_error_msg_show(msg,"",3,"");}}});};function getHttpRequestObject(){var http_request=false;if(window.XMLHttpRequest){http_request=new XMLHttpRequest();if(http_request.overrideMimeType){http_request.overrideMimeType('text/xml');}}else if(window.ActiveXObject){try{http_request=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){try{http_request=new ActiveXObject("Microsoft.XMLHTTP");}catch(e){}}};if(!http_request){alert(I18n.unsupportedHttpProtocol);return false;};return http_request;};function getAjaxSubmitStr(name,firstFlag){if($N(name).length==0){return "";};var value=$N(name)[0].value;if(!value||value==null||value==""){return "";};if(firstFlag)return name+"="+value;else return "&"+name+"="+value;};function isNullValue(name,chineseName){if($N(name).length==0){_error_msg_show(chineseName+I18n.nullValueTipSuffix,"",3,"");return true;};var value=$N(name)[0].value;if(!value||value==null||value==""){_error_msg_show(chineseName+I18n.nullValueTipSuffix,"",3,"");return true;};return false;};function openWindow(link,width,height,windowParam){var widthvalue=(window.screen.width-width)/2;var heightvalue=(window.screen.height-height)/2;var PopWindow;PopWindow=window.open(link,"","width="+width+",height="+height+","+windowParam+",left="+widthvalue+",top="+heightvalue,true);PopWindow.focus();};function doVote(xId){var cs=$N("vote."+xId);if(!cs||cs==null||cs==""||cs.length==0){_error_msg_show(I18n.voteItemNotExist,"",3,"");return true;};var ps="";var count=0;for(var i=0;i<cs.length;i++){if(cs[i].checked){if(count>0){ps=ps+"&";};ps=ps+"vote."+xId+"="+cs[i].value;count++;}};if(count==0){_error_msg_show(I18n.voteItemNotSelected,"",3,"");return true;};var url=_contextPath+"/cfn?cmsfn=0301";ps+="&vote.vbox_id="+xId;var nextUrl=_contextPath+"/cc?url=_voteResult&vote.vbox_id="+xId+"&nc=true";url=_contextPath+"/cfn?cmsfn=0301&"+ps+"&forward="+encodeURIComponent(nextUrl)+"&action="+encodeURIComponent(url+"&"+ps);openWindow(url,400,400,"resizable=yes");};function doViewVote(xId){openWindow(_contextPath+"/cc?url=_voteResult&vote.vbox_id="+xId+"&nc=true",400,400,"resizable=yes");};function chgAuthImg(){var authImg=$('auth_img');authImg.src=_contextPath+"/cfn?cmsfn=0401"+'&'+Math.random();var cNum=$('checkNum.inputNum');cNum.value="";};function doCheckNum(){var url=_contextPath+"/cfn?cmsfn=0402";var inputNum=$("checkNum.inputNum");url+="&checkNum.inputNum="+inputNum.value;new Ajax.Request(url,{method:'get',onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){var sa=$("successAction");var forward=$("forward");if(sa.value!=""){new Ajax.Request(sa.value,{method:'get',onSuccess:function(transport){window.location=forward.value+"&nc=true";}});}else{window.location=forward.value+"&nc=true";}}else{chgAuthImg();inputNum=$("checkNum.inputNum");inputNum.value="";inputNum.focus();_error_msg_show(msg,"",3,"");}}});};function getFormParams(formName,isEncodeURI){return $(formName).serialize(false);};var Form={};Form.Methods={serialize:function(getHash){var formE=this;if(!formE||!formE.tagName||formE.tagName.toLowerCase()!="form"){throw new Error(I18n.formBindFailure);};var params={};var inputs=formE.getElementsByTagName("input");var count=0;if(inputs){for(var i=0;i<inputs.length;i++){var input=inputs[i];var tagType=input.type.toLowerCase();if(tagType=="image"||tagType=="button"||tagType=="file"||tagType=="reset"||tagType=="submit"){continue;};if(input.disabled||!input.name){continue;};if((tagType=="radio"||tagType=="checkbox")){if(input.checked){this._addParam(params,input.name,input.value);}}else{this._addParam(params,input.name,input.value);}}};var selects=formE.getElementsByTagName("select");if(selects){for(var i=0;i<selects.length;i++){var select=selects[i];if(select.disabled||!select.name){continue;};if(select.type=="select-one"){this._addParam(params,select.name,select.options[select.selectedIndex].value);}else{for(var j=0;j<select.options.length;j++){if(select.options[j].selected){this._addParam(params,select.name,select.options[j].value);}}}}};var areas=formE.getElementsByTagName("textarea");if(areas){for(var i=0;i<areas.length;i++){var area=areas[i];if(area.disabled||!area.name){continue;};this._addParam(params,area.name,area.value);}};return getHash?params:this.toQueryString(params);},_addParam:function(result,key,value){if(value!=null){if(key in result){if(result[key].constructor !=Array)result[key]=[result[key]];result[key].push(value);}else result[key]=value;}},toQueryString:function(obj){var parts=[];for(var key in obj){var value=obj[key];if(value&&typeof value=='object'){if(value.constructor==Array){for(var i=0;i<value.length;i++){this.addQueryPair(parts,key,value[i]);}}};this.addQueryPair(parts,key,value);};return parts.join('&');},addQueryPair:function(result,name,value){var pair=name+"="+encodeURIComponent(value);result.push(pair);}};function doUserReg(successUrl){var e=getEventSrcElement();if(e!=null){e.disabled=true;};var url=_contextPath+"/cfn?cmsfn=0501";new Ajax.Request(url,{method:'post',parameters:$('userRegForm').serialize(true),onSuccess:function(transport){if(e!=null){e.disabled=false;};userInfoResponse(transport,successUrl);}});};function userInfoResponse(transport,successUrl){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;if(!successUrl){request.set("nc","true");var nowLocation=request.getUrl();successUrl=nowLocation;};if(status=="0"){var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;_error_msg_show(msg,"window.location='"+successUrl+"';",3,"");}else{var errorInfos=$N("_error");if(errorInfos.length!=undefined&&errorInfos.length>0){var eiLength=errorInfos.length;for(var h=0;h<eiLength;h++){errorInfos.item(0).removeNode(true);}};var msgNodes=root.getElementsByTagName('message');if(msgNodes.length==1&&msgNodes.item(0).getElementsByTagName('key').length==0){var msg=msgNodes.item(0).firstChild.data;request.set("nc","true");var nowLocation=request.getUrl();_error_msg_show(msg,"window.location='"+nowLocation+"'",3,"");return;};var info="";if(msgNodes.length>0){var count=0;for(var i=0;i<msgNodes.length;i++){var msg=msgNodes.item(i);if(count>0){info+="\n";};var mKey=msg.getElementsByTagName('key')[0].firstChild.data;var mValue=msg.getElementsByTagName('value')[0].firstChild.data;info+=mKey+mValue;var errorE=$N(mKey)[0];if(errorE){var parentE=errorE.parentNode;var	errorInfoE;if(browser.isIE){errorInfoE=document.createElement("<b class=\"user_error_info\" id=\"_error\" name=\"_error\"></b>");}else{errorInfoE=document.createElement("b");errorInfoE.setAttribute("class","user_error_info");errorInfoE.setAttribute("id","_error");errorInfoE.setAttribute("name","_error");};parentE.appendChild(errorInfoE);errorInfoE.innerHTML=mValue;}else{alert(I18n.userNotFoundItem+mKey);}}}}};function doUserUpdate(successUrl){var url=_contextPath+"/cfn?cmsfn=0504";new Ajax.Request(url,{method:'post',parameters:$('userUpdateForm').serialize(true),onSuccess:function(transport){userInfoResponse(transport,successUrl);}});};function doUserDuplicateCheck(){var url=_contextPath+"/cfn?cmsfn=0503";var uId=$("user_id");if(uId.value==""||uId.value==null){request.set("nc","true");var nowLocation=request.getUrl();_error_msg_show(I18n.userIdEmpty,"window.location='"+nowLocation+"'",5,"");uId.focus();return;};var ps="uId="+uId.value;new Ajax.Request(url,{method:'get',parameters:ps,onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){if(msg=="NULL"){msg=I18n.userNotUsed;};_error_msg_show(msg,"",3,"");}else{if(msg=="NULL"){msg=I18n.userAlreadyExist;};_error_msg_show(msg,"",5,"");}}});};function doUserLogin(successUrl){var url=_contextPath+"/cfn?cmsfn=0505";var uId=$("user_id");if(!successUrl){request.set("nc","true");successUrl=request.getUrl();};if(uId.value==""||uId.value==null){_error_msg_show(I18n.userIdEmpty,"",5,"");uId.focus();return;};var uPasswd=$("user_passwd");if(uPasswd.value==""||uPasswd.value==null){_error_msg_show(I18n.userPasswordEmpty,"",5,"");uPasswd.focus();return;};var cNum=$("checkNum.inputNum");var ps="user_id="+uId.value+"&user_passwd="+uPasswd.value+"&checkNum.inputNum="+cNum.value;new Ajax.Request(url,{method:'get',parameters:ps,onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){window.location=successUrl;}else{_error_msg_show(msg,"",5,"");chgAuthImg();}}});};function doUserInfoEdit(){window.location=_contextPath+'/cc?url=_userEdit&nc=true';};function doRegisterUser(){window.location=_contextPath+'/cc?url=_userReg&nc=true';};function doPasswdRetrieve(){window.location=_contextPath+'/cc?url=_forgetPassword&nc=true';};function doUserLogout(){var url=_contextPath+'/cfn?cmsfn=0506';request.set("nc","true");var nowLocation=request.getUrl();new Ajax.Request(url,{method:'get',onSuccess:function(transport){window.location=nowLocation;return;}});return;};function doRetrievePasswd(){var url=_contextPath+'/cfn?cmsfn=0507';var uId=$N("user_id")[0];var uEmail=$N("user_email")[0];var uQuestion=$N("user_question")[0];var uanswer=$N("user_answer")[0];var cNum=$("checkNum.inputNum");var ps="user_id="+uId.value+"&user_email="+uEmail.value+"&user_question="+uQuestion.value+"&user_answer="+uanswer.value+"&checkNum.inputNum="+cNum.value;new Ajax.Request(url,{method:'post',parameters:ps,onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){_error_msg_show(I18n.userRetrievePasswordSuccess,"",3,"");}else{if(msg=="NULL"){msg=I18n.userRetrievePasswordFailure;};_error_msg_show(msg,"",5,"");}}});};function changeErrorStackStatus(){var e=$("errorStackInfo");if(e.style.display=="none"){e.style.display="block";}else{e.style.display="none";}};function cmsDownload(cmsId,fld,flag){if(!cmsId||!fld){alert(I18n.downloadFileNotExist);return false;};var url=_contextPath+"/down?ID="+cmsId+"&fld="+fld;new Ajax.Request(url,{method:'get',onSuccess:function(transport){var status=transport.responseText;if(status&&status=="true"){return true;}else{alert(I18n.downloadInfoUpdateFailure);return false;}}});};function changeLocale(locale){var e=getEventSrcElement();setCookie("_cmsLocale",locale);window.location.reload();};function showLocaleSelector(){var e=getEventSrcElement();var menu=$("localeSelect");menu.style.position="absolute";menu.style.display="block";var ePos=getElementPosition(e);menu.style.left=ePos.left+menu.offsetWidth<document.body.offsetWidth?ePos.left+"px":((window.screen.width-document.body.offsetWidth)/2+document.body.offsetWidth-menu.offsetWidth-11)+"px";menu.style.top=ePos.top+e.offsetHeight;};function hiddenLocaleSelector(event){var label=$("changeLocale");var menu=$("localeSelect");var ePos=getElementPosition(menu);var eventX=event.x?event.x:event.pageX;eventX+=document.documentElement.scrollLeft;var eventY=event.y?event.y:event.pageY;eventY+=document.documentElement.scrollTop;if(eventX>0&&eventX<ePos.left+menu.offsetWidth&&eventX>ePos.left&&eventY>0&&eventY<ePos.top+menu.offsetHeight&&eventY>ePos.top)return;menu.style.display="none";menu.scrollLeft=0;menu.scrollTop=0;};function getElementPosition(obj){var left_offset=obj.offsetLeft;var top_offset=obj.offsetTop;while((obj=obj.offsetParent)!=null){left_offset+=obj.offsetLeft;top_offset+=obj.offsetTop;};return{'left':left_offset,'top':top_offset};};function includeJs(file){new Ajax.Request(file,{asynchronous:false,method:'get',onSuccess:function(transport){document.write("<script language=\"javascript\" type=\"text/javascript\">"+ transport.responseText+ "</script>");}});};function includeCss(file){new Ajax.Request(file,{asynchronous:false,method:'get',onSuccess:function(transport){document.write("<style>"+transport.responseText+"</style>");}});};function OspodSlide(pic,width,height,link,text,itv,spd){if(arguments.length<1){alert(I18n.slideIllegalParameter);return false;};var interval=itv?itv:3000;var duration=spd?spd:50;var xsImgWidth=width?width:100;var xsImgHeight=height?height:100;var link=link?link:'';var texts=text?text:'';texts=texts.replace("\"\"","&quot;");var xsTextBar=1;var dNum=4;var pics=pic;var textHgt=25;var textBgc='#c0c0c0';var slideType=1;var slideBgc='#000000';this.setSlideType=function(type){slideType=type;};this.setTextBgc=function(tbgc){textBgc=tbgc;};this.setTextHgt=function(thgt){textHgt=thgt;};this.setdNum=function(dnum){dNum=dnum;};this.setSlideBgc=function(bgColor){slideBgc=bgColor;};var xsImgs=new Array();var xsImgLinks=new Array();var xsImgTexts=new Array();var xsTempImgs=new Array();var xsTempImg=new Array();var offsetIndex=0;var transitions=new Array;transitions[0]="progid:DXImageTransform.Microsoft.Fade(duration="+duration/50+")";transitions[1]="progid:DXImageTransform.Microsoft.GradientWipe(duration="+duration/50+")";transitions[2]="progid:DXImageTransform.Microsoft.Pixelate(maxSquare=10,duration="+duration/50+")";transitions[3]="progid:DXImageTransform.Microsoft.Barn(function=15, duration="+duration/50+")";var transition_count=transitions.length;var timerId=-1;var curImg=0;this.initSize=function(){var tHeight=Math.floor(xsImgHeight*0.75);if(browser.isIE7){var bImgWidth=(xsImgWidth-18)/dNum;var bImgHeight=xsImgHeight>350?xsImgHeight*0.225:xsImgHeight*0.21-1;}else if(browser.isIE){var bImgWidth=(xsImgWidth-18)/dNum;var bImgHeight=xsImgHeight>350?xsImgHeight*0.225:xsImgHeight*0.21-1;}else{var bImgWidth=(xsImgWidth-18)/dNum;var bImgHeight=xsImgHeight>350?xsImgHeight*0.225:xsImgHeight*0.20;};var bWidth=xsImgWidth;var bHeight=Math.floor(xsImgHeight*0.25);return{'tHeight':tHeight,'bWidth':bWidth,'bImgHeight':bImgHeight,'bImgWidth':bImgWidth,"bHeight":bHeight};};var bSize;this.init=function(){bSize=this.initSize();xsImgs=pics.split("|");if(link.length==0){for(var i=0;i<xsImgs.length;i++){xsImgLinks[i]='';}}else{xsImgLinks=link.split("|");};if(texts.length==0){for(var i=0;i<xsImgs.length;i++){xsImgTexts[i]='';}}else{xsImgTexts=texts.split("|");};if(slideType){document.write("<style type=\"text/css\">");document.write("#slidearea{background-color:"+slideBgc+";border:1px solid #959595;width:"+xsImgWidth+"px;height:"+xsImgHeight+"px;};");document.write("#slidearea #slidebody{ width:100%; height:"+bSize['tHeight']+"px; overflow: hidden; margin: 0 auto; text-align: center;vertical-align:middle;}; ");document.write("#slidearea #slidebody .img{*margin-top:expression((parentElement.parentElement.offsetHeight-this.offsetHeight)/2);};");document.write("#slidearea #slidefooter{overflow:hidden;height:"+bSize['bHeight']+"px;width:100%;};");document.write("#slidearea  img{border:0px};");document.write("#slidearea #slidefooter img.img1{border:1px solid #959595;padding:1px;};");document.write("#slidearea #slidefooter img.img2{border:1px solid #FF0000;padding:1px;};");document.write("#slidearea #slidefooter img.img3{border:1px solid #33FF00;padding:1px;};");document.write("#slidearea #slidefooter table{vertical-align:middle;border-collapse:collapse; margin:1px auto;width:100%;};");document.write("#slidearea #slidefooter table td{vertical-align:middle;text-align:center;width:"+bSize['bImgWidth']+"px;};");document.write("#slidearea #slidetext {overflow:hidden;word-break:break-all;text-align:center;width:100%;background-color: "+textBgc+"; filter:alpha(opacity=80);border-bottom:1px solid #959595;margin-top:-"+textHgt+"px;line-height:"+textHgt+"px;height:"+textHgt+"px;opacity: 0.80;font-family: 黑体; font-size:16px;color:#000000;};");document.write("</style>");document.write("<div id=\"slidearea\">");document.write("<div id=\"slidebody\">");if(xsImgs.length!=0){document.write("<a id=\"imglink\" href=\"" + xsImgLinks[0] + "\" target=\"_blank\"><img id=\"xsimgV\" title=\"" + xsImgTexts[0] + "\" src=\"" + xsImgs[0] + "\" width="+bSize['bWidth']+" height="+bSize['tHeight']+"\" onload=\"imgZoomer(this,"+bSize['bWidth']+","+bSize['tHeight']+");\"/><\/a>");};var xsTempV=$('xsimgV');for(var i=0;i<xsImgs.length;i++){xsTempImg[i]=xsTempV.cloneNode(true);xsTempImg[i].src=xsImgs[i];};document.write("<\/div>");document.write("<div id=\"slidetext\">"+xsImgTexts[0]+"<\/div>");if(xsTextBar!=0){document.write("<div id=\"slidefooter\">");document.write("<table cellpadding=0 cellspacing=0 style=\"table-layout:fixed;\" ><tr><td style=\"width:9px;\" align=\"left\" nowrap><a href=\"#\" onclick=\"OspodSlide.prototype.forward(-1);return false\"><img src=\"img/focus_back1.gif\" onmouseout=\"this.src='img/focus_back1.gif';\" onmouseover=\"javascript:this.src='img/focus_back2.gif';\" onload=\"imgZoomer(this,9," + bSize['bImgHeight'] + ")\"></a></td><td style=\"width:"+(bSize['bWidth']-18)+"px;height:"+(bSize['bImgHeight'])+"px;\"><table style=\"width:"+(bSize['bWidth']-18)+"px;height:"+(bSize['bImgHeight'])+"px;\"><tr>");dNum=xsImgs.length>dNum?dNum:xsImgs.length;for(var i=0;i<dNum;i++){document.write("<td><a href=\"#\" id=\"imgtd"+i+"\" onclick=\"OspodSlide.prototype.selectImg("+i+");return false\"><img class=\"img1\" id=\"xs"+i+"\" src=\""+xsImgs[i]+"\" width=\""+bSize['bImgWidth']+"\" height=\""+bSize['bImgHeight']+"\" onload=\"imgZoomer(this,"+bSize['bImgWidth']+","+bSize['bImgHeight']+");OspodSlide.prototype.mouseSelect(this,"+i+");\"></a></td>");};var xsTemp=$('xs0');for(var i=0;i<xsImgs.length;i++){xsTempImgs[i]=xsTemp.cloneNode(true);xsTempImgs[i].src=xsImgs[i];xsTempImgs[i].id='xs'+i;};document.write("</tr></table></td><td style=\"width:9px;\" align=\"right\" nowrap ><a href=\"#\" onclick=\"OspodSlide.prototype.forward(1,1);return false\"><img style=\"text-align:right;\" src=\"img/focus_forward1.gif\" onmouseout=\"this.src='img/focus_forward1.gif';\" onmouseover=\"javascript:this.src='img/focus_forward2.gif';\" onload=\"imgZoomer(this,9," + bSize['bImgHeight'] + ")\"></a></td><\/tr><\/table>");document.write("<\/div>");};document.write("<\/div>");}else{document.write("<style type=\"text/css\">#slidebody {background-color:"+slideBgc+";border:1px solid #959595; width:" + xsImgWidth + "px; height:" + xsImgHeight + "px; overflow: hidden; margin: 0 auto; text-align: center; vertical-align:middle;display: table-cell;}; #slidearea img {*margin-top:expression((parentElement.parentElement.offsetHeight-this.offsetHeight)/2);};</style>");document.write("<div id=\"slidebody\">");if(xsImgs.length!=0){document.write("<a id=\"imglink\" href=\"" + xsImgLinks[0] + "\" target=\"_blank\"><img id=\"xsimgV\" title=\"" + xsImgTexts[0] + "\" src=\"" + xsImgs[0] + "\" width="+xsImgWidth+" height="+xsImgHeight+"\" onload=\"imgZoomer(this,"+xsImgWidth+","+xsImgHeight+");\"/><\/a>");var xsTempV=$('xsimgV');for(var i=0;i<xsImgs.length;i++){xsTempImg[i]=xsTempV.cloneNode(true);xsTempImg[i].src=xsImgs[i];}};document.write("<\/div>")};window.setTimeout("OspodSlide.prototype.play()",interval);};OspodSlide.prototype.mouseSelect=function(obj,i){obj.onmouseover=OspodSlide.prototype.slideOver.bind(obj,i);obj.onmouseout=OspodSlide.prototype.slideOut.bind(obj,i);if(obj.id=='xs0'){$('xs0').style.border="1px solid #33FF00";$('xs0').style.padding="1px";var Oimg=document.createElement('img');Oimg.src=obj.src;imgZoomer(Oimg,bSize['bImgWidth'],bSize['bImgHeight']);$('xs0').style.height=Oimg.height;$('xs0').style.width=Oimg.width;}};OspodSlide.prototype.slideOver=function(img,i){img.style.border="1px solid #FF0000";img.style.padding="1px";};OspodSlide.prototype.slideOut=function(img,i){var Oimg=document.createElement('img');Oimg.src=xsTempImgs[i].src;imgZoomer(Oimg,bSize['bImgWidth'],bSize['bImgHeight']);img.height=Oimg.height;img.width=Oimg.width;img.style.border="1px solid #959595";img.style.padding="1px";if(i==curImg){OspodSlide.prototype.selectedImg(curImg,0);}};OspodSlide.prototype.changeSlide=function(){if(document.all){var do_transition=Math.floor(Math.random()*transition_count);$('slidebody').style.filter=transitions[do_transition];$('slidebody').filters[0].Apply();};if(xsImgs.length!=0){$('imglink').href=xsImgLinks[curImg];$('imglink').innerHTML="";$('imglink').appendChild(xsTempImg[curImg]);$('xsimgV').title=xsImgTexts[curImg];if(slideType){var slideText=xsImgTexts[curImg];$('slidetext').innerHTML=slideText;};if(document.all){$('slidebody').filters[0].Play();}}};OspodSlide.prototype.forward=function(j,type){if(j){curImg=j;}else{curImg++;};if(dNum){if(curImg==1){for(var i=0;i<xsImgs.length;i++){if(i==0){var xsImges=xsTempImgs[i];var xsImg=xsTempImg[i];var xsText=xsImgTexts[i];var xsLink=xsImgLinks[i];xsTempImgs[i]=xsTempImgs[i+1];xsTempImg[i]=xsTempImg[i+1];xsImgTexts[i]=xsImgTexts[i+1];xsImgLinks[i]=xsImgLinks[i+1];}else if(i==(xsImgs.length-1)){xsTempImgs[i]=xsImges;xsTempImg[i]=xsImg;xsImgTexts[i]=xsText;xsImgLinks[i]=xsLink;}else{xsTempImgs[i]=xsTempImgs[i+1];xsTempImg[i]=xsTempImg[i+1];xsImgTexts[i]=xsImgTexts[i+1];xsImgLinks[i]=xsImgLinks[i+1]}};OspodSlide.prototype.selectedImg(curImg-1,0);if(type){window.clearInterval(timerId);timerId=window.setInterval('OspodSlide.prototype.forward();',interval);}}else{var mPs=new Array();var mP=new Array();var mT=new Array();var mL=new Array();for(var i=0;i<xsImgs.length;i++){mPs[i]=xsTempImgs[i];mP[i]=xsTempImg[i];mT[i]=xsImgTexts[i];mL[i]=xsImgLinks[i];};if(j==-1){curImg=xsImgs.length+j;};for(var i=0;i<xsImgs.length;i++){var m=i-curImg;if(m<0){m=xsImgs.length-curImg+i;};xsTempImgs[m]=mPs[i];xsTempImg[m]=mP[i];xsImgTexts[m]=mT[i];xsImgLinks[m]=mL[i];};OspodSlide.prototype.selectedImg(xsImgs.length-curImg-1,0);window.clearInterval(timerId);timerId=window.setInterval('OspodSlide.prototype.forward();',interval);};curImg=0;var imgfooter="";dNum=(xsImgs.length)>dNum?dNum:xsImgs.length;for(var i=0;i<dNum;i++){var Oimg=new Image();Oimg.src=xsTempImgs[i].src;imgZoomer(Oimg,bSize['bImgWidth'],bSize['bImgHeight']);$('imgtd'+i).innerHTML="";$('imgtd'+i).appendChild(xsTempImgs[i]);$(xsTempImgs[i].id).style.width=Oimg.width;$(xsTempImgs[i].id).style.height=Oimg.height;}}else if(curImg>=dNum){curImg=0;};OspodSlide.prototype.changeSlide();};OspodSlide.prototype.forward_e=function(){curImg++;if(curImg>=xsImgs.length){curImg=0;};OspodSlide.prototype.changeSlide();};OspodSlide.prototype.rewind=function(){curImg--;if(curImg<0){curImg=xsImgs.length-1;};OspodSlide.prototype.changeSlide();};OspodSlide.prototype.play=function(){if(timerId==-1){if(slideType){timerId=window.setInterval('OspodSlide.prototype.forward();',interval);}else{timerId=window.setInterval('OspodSlide.prototype.forward_e();',interval);}}};OspodSlide.prototype.selectImg=function(i){OspodSlide.prototype.selectedImg(i,1);};OspodSlide.prototype.selectedImg=function(j,type){var img=document.createElement('img');dNum=xsImgs.length>dNum?dNum:xsImgs.length;for(var i=0;i<dNum;i++){if(i==j){xsTempImgs[j].style.border="1px solid #33FF00";xsTempImgs[j].style.padding="1px";if($('xs'+j)){$('xs'+j).style.border="1px solid #33FF00";$('xs'+j).style.padding="1px";};img.src=xsTempImgs[j].src;imgZoomer(img,bSize['bImgWidth'],bSize['bImgHeight']);xsTempImgs[j].height=img.height;xsTempImgs[j].width=img.width;if(type){if(j==0){img.src=xsTempImgs[dNum-1].src;imgZoomer(img,bSize['bImgWidth'],bSize['bImgHeight']);xsTempImgs[dNum-1].className="img1";xsTempImgs[dNum-1].height=img.height;xsTempImgs[dNum-1].width=img.width;}else{img.src=xsTempImgs[j-1].src;imgZoomer(img,bSize['bImgWidth'],bSize['bImgHeight']);xsTempImgs[j-1].style.border="1px solid #959595";xsTempImgs[j-1].style.padding="1px";xsTempImgs[j-1].height=img.height;xsTempImgs[j-1].width=img.width;};OspodSlide.prototype.forward(j);}}else{xsTempImgs[i].style.border="1px solid #959595";xsTempImgs[i].style.padding="1px";img.src=xsTempImgs[i].src;imgZoomer(img,bSize['bImgWidth'],bSize['bImgHeight']);xsTempImgs[i].height=img.height;xsTempImgs[i].width=img.width;}}}};function imgZoomer(imgObj,canvas_width,canvas_height){var obj=imgObj;var src_width=GetImageWidth(obj);var src_height=GetImageHeight(obj);var widthScale=src_width/canvas_width;var heightScale=src_height/canvas_height;if(widthScale>=1||heightScale>=1){if(widthScale<heightScale){obj.width=src_width/heightScale;obj.height=canvas_height;}else{obj.width=canvas_width;obj.height=src_height/widthScale;}}else{obj.width=src_width;obj.height=src_height;}};var OriginImage=new Image();function GetImageWidth(oImage){if(OriginImage.src!=oImage.src)OriginImage.src=oImage.src;return OriginImage.width;};function GetImageHeight(oImage){if(OriginImage.src!=oImage.src)OriginImage.src=oImage.src;return OriginImage.height;};function ImageViewer(obj,dir){var IMGDIR=(dir!=null)?dir:"img";var zoomobj=new Array();var zoomimglayer_bg=$('zoomimglayer_bg');var zoomimglayer=$('zoomimglayer');this.zoom=function(obj){var append_parent=$('append_parent');if(!append_parent){append_parent=document.createElement('div');append_parent.id='append_parent';document.body.appendChild(append_parent);};zimg=obj.src;if(zimg){zimg=zimg.replace("_mini.",".");};if(!zoomimglayer_bg){zoomimglayer_bg=document.createElement('div');zoomimglayer_bg.id='zoomimglayer_bg';zoomimglayer_bg.style.position='absolute';zoomimglayer_bg.style.top='0px';zoomimglayer_bg.style.left='0px';zoomimglayer_bg.style.width=document.documentElement.clientWidth>document.body.clientWidth?document.documentElement.clientWidth+'px':document.body.clientWidth+'px';zoomimglayer_bg.style.height=document.body.scrollHeight+'px';zoomimglayer_bg.style.backgroundColor='#000';zoomimglayer_bg.style.display='none';zoomimglayer_bg.style.filter='progid:DXImageTransform.Microsoft.Alpha(opacity=80,finishOpacity=100,style=0)';zoomimglayer_bg.style.opacity=0.8;append_parent.appendChild(zoomimglayer_bg);zoomimglayer=document.createElement('div');zoomimglayer.id='zoomimglayer';zoomimglayer.style.position='absolute';zoomimglayer.style.padding=0;append_parent.appendChild(zoomimglayer);};zoomobj['srcinfo']=this.fetchOffset(obj);zoomobj['srcobj']=obj;zoomobj['zimg']=zimg;zoomimglayer.style.display='';zoomimglayer.style.left=zoomobj['srcinfo']['left']+'px';zoomimglayer.style.top=zoomobj['srcinfo']['top']+'px';zoomimglayer.style.width=zoomobj['srcobj'].width+'px';zoomimglayer.style.height=zoomobj['srcobj'].height+'px';zoomimglayer.style.border="0px solid #FF0000";zoomimglayer.style.filter='progid:DXImageTransform.Microsoft.Alpha(opacity=40,finishOpacity=100,style=0)';zoomimglayer.style.opacity=0.4;zoomimglayer.style.zIndex=999;zoomimglayer.innerHTML='<table width="100%" height="100%" cellspacing="0" cellpadding="0" style="border:1px solid #FF0000;"><tr><td align="center" valign="middle"><img src="'+IMGDIR+'/loading.gif"></td></tr></table><div style="position:absolute;top:-100000px;visibility:hidden"><img src="'+zoomobj['zimg']+'" onload="javascript:ImageViewer.prototype.zoomimgresize(this);"></div>';};this.fetchOffset=function(obj){var left_offset=obj.offsetLeft;var top_offset=obj.offsetTop;while((obj=obj.offsetParent)!=null){left_offset+=obj.offsetLeft;top_offset+=obj.offsetTop;};return{'left':left_offset,'top':top_offset};};var zoomdragstart=new Array();var zoomclick=0;ImageViewer.prototype.zoomdrag=function(e,op){if(op==1){zoomclick=1;zoomdragstart=browser.isIE?[event.clientX,event.clientY]:[e.clientX,e.clientY];zoomdragstart[2]=parseInt(zoomimglayer.style.left);zoomdragstart[3]=parseInt(zoomimglayer.style.top);ImageViewer.prototype.doane(e);}else if(op==2&&zoomdragstart[0]){zoomclick=0;var zoomdragnow=browser.isIE?[event.clientX,event.clientY]:[e.clientX,e.clientY];zoomimglayer.style.left=(zoomdragstart[2]+zoomdragnow[0]-zoomdragstart[0])+'px';zoomimglayer.style.top=(zoomdragstart[3]+zoomdragnow[1]-zoomdragstart[1])+'px';ImageViewer.prototype.doane(e);}else if(op==3){if(zoomclick){ImageViewer.prototype.zoomclose();};zoomdragstart=[];ImageViewer.prototype.doane(e);}};ImageViewer.prototype.doane=function(event){e=event?event:window.event;if(browser.isIE){e.returnValue=false;e.cancelBubble=true;}else if(e){e.stopPropagation();e.preventDefault();}};ImageViewer.prototype.setImageDir=function(dir){IMGDIR=dir;};ImageViewer.prototype.zoomST=function(c){if(zoomimglayer.style.display==''){zoomimglayer.style.left=(parseInt(zoomimglayer.style.left)+zoomobj['x'])+'px';zoomimglayer.style.top=(parseInt(zoomimglayer.style.top)+zoomobj['y'])+'px';zoomimglayer.style.width=(parseInt(zoomimglayer.style.width)+zoomobj['w'])+'px';zoomimglayer.style.height=(parseInt(zoomimglayer.style.height)+zoomobj['h'])+'px';var opacity=c*20;zoomimglayer.style.filter='progid:DXImageTransform.Microsoft.Alpha(opacity='+opacity+',finishOpacity=100,style=0)';zoomimglayer.style.opacity=opacity/100;c++;if(c<=5){setTimeout('ImageViewer.prototype.zoomST('+c+')',5);}else{zoomimglayer.style.filter='';zoomimglayer_bg.style.display='';zoomimglayer.innerHTML='<table cellspacing="0" cellpadding="2"><tr><td style="text-align: right;color:white;" nowrap>'+I18n.imageViewerZoomTip+'<a href="'+zoomobj['zimg']+'" target="_blank"><img src="'+IMGDIR+'/newwindow.gif" border="0" style="vertical-align: middle" title="'+I18n.imageViewerOpenTip+'" /></a> <a href="javascript:return false;" onclick="ImageViewer.prototype.zoomimgadjust(event, 1)"><img src="'+IMGDIR+'/resize.gif" border="0" style="vertical-align: middle" title="'+I18n.imageViewerNormalSizeTip+'" /></a> <a href="javascript:ImageViewer.prototype.zoomclose();"><img style="vertical-align: middle" src="'+IMGDIR+'/close.gif" title="'+I18n.imageViewerCloseTip+'" /></a>&nbsp;</td></tr><tr><td align="center" id="zoomimgbox"><img id="zoomimg"  style="cursor: move; margin: 5px;" src="'+zoomobj['zimg']+'" width="'+zoomimglayer.style.width+'" height="'+zoomimglayer.style.height+'"></td></tr></table>';zoomimglayer.style.overflow='visible';zoomimglayer.style.width=zoomimglayer.style.height='auto';if(browser.isIE){zoomimglayer.onmousewheel=ImageViewer.prototype.zoomimgadjust;$('zoomimgbox').onmousedown=ImageViewer.prototype.zoomdrag.bind(event,1);$('zoomimgbox').onmousemove=ImageViewer.prototype.zoomdrag.bind(event,2);$('zoomimgbox').onmouseup=ImageViewer.prototype.zoomdrag.bind(event,3);}else{zoomimglayer.addEventListener("DOMMouseScroll",ImageViewer.prototype.zoomimgadjust,false);}}}};ImageViewer.prototype.zoomimgresize=function(obj){zoomobj['zimginfo']=[obj.width,obj.height];var r=obj.width/obj.height;var w=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;w=w*0.95;w=obj.width>w?w:obj.width;var h=w/r;var clientHeight=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var scrollTop=document.body.scrollTop?document.body.scrollTop:document.documentElement.scrollTop;if(h>clientHeight){h=clientHeight;w=h*r;};var l=((document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth)-w)/2;var t=h<clientHeight?(clientHeight-h)/2:0;t+=+scrollTop;zoomobj['x']=(l-zoomobj['srcinfo']['left'])/5;zoomobj['y']=(t-zoomobj['srcinfo']['top'])/5;zoomobj['w']=(w-zoomobj['srcobj'].width)/5;zoomobj['h']=(h-zoomobj['srcobj'].height)/5;zoomimglayer.style.filter='';zoomimglayer.innerHTML='';setTimeout('ImageViewer.prototype.zoomST(1)',5);};ImageViewer.prototype.zoomimgadjust=function(e,a){var zoomimg=$('zoomimg');if(!a){if(!e)e=window.event;if(e.altKey||e.shiftKey||e.ctrlKey)return;var l=parseInt(zoomimglayer.style.left);var t=parseInt(zoomimglayer.style.top);var img=GetImageSize(zoomobj['srcobj']);var scale=img.width/img.height;if(e.wheelDelta<=0||e.detail>0){if(zoomimg.width<=100||zoomimg.height<=100){ImageViewer.prototype.doane(e);return;};zoomimg.width-=zoomobj['zimginfo'][0]/10;zoomimg.height-=(zoomobj['zimginfo'][1]/10)*scale;}else{zoomimg.width+=zoomobj['zimginfo'][0]/10;zoomimg.height+=(zoomobj['zimginfo'][1]/10)*scale;}}else{zoomimg.width=zoomobj['zimginfo'][0];zoomimg.height=zoomobj['zimginfo'][1];};var clientHeight=document.documentElement.clientHeight?document.documentElement.clientHeight:document.body.clientHeight;var scrollTop=document.body.scrollTop?document.body.scrollTop:document.documentElement.scrollTop;var clientWidth=document.documentElement.clientWidth?document.documentElement.clientWidth:document.body.clientWidth;var l=(clientWidth-zoomimg.clientWidth)/2;l=l>0?l:0;var t=(clientHeight-zoomimg.clientHeight)/2+scrollTop;t=t>0?t:0;zoomimglayer.style.left=l+'px';zoomimglayer.style.top=t+'px';zoomimglayer_bg.style.height=t+zoomimglayer.clientHeight>zoomimglayer_bg.clientHeight?(t+zoomimglayer.clientHeight)+'px':zoomimglayer_bg.style.height;ImageViewer.prototype.doane(e);};ImageViewer.prototype.zoomclose=function(){zoomimglayer.innerHTML='';zoomimglayer.style.display='none';zoomimglayer_bg.style.display='none';};this.zoom(obj);};function Marquee(elm,width,height,spd,type,wspace){if(arguments.length<1){alert(I18n.marqueeIdEmpty);return false;};var element=elm;var scrollwidth=width?width:800;var scrollheight=height?height:200;scrollwidth=parseInt(scrollwidth);scrollheight=parseInt(scrollheight);var scrollwspace=wspace?wspace:5;var scrolltype=type?type:3;var speed=spd?spd:30;var scrolltext=new Array();var obj1=document.getElementById(element);if(!obj1){alert(I18n.marqueeIllegalParameter);return false;};obj1.style.height=scrollheight+'px';obj1.style.width=scrollwidth+'px';obj1.style.border='0px solid #000';var obj2=document.createElement("div");obj2.id=element+'obj2';var obj3=document.createElement("div");obj3.id=element+"obj3";obj2.style.border='0px solid #000';var objtab=document.createElement('table');var objtr=document.createElement('tr');var objtd=document.createElement('td');objtd.innerHTML=obj1.innerHTML;obj1.innerHTML="";objtab.style.display="inline";objtab.cellpadding="0";objtab.cellspacing="0";objtab.id=element+'tab';objtab.style.border="0px solid #FF0000";objtd.style.whiteSpace="nowrap";objtr.appendChild(objtd);objtab.appendChild(objtr);obj2.innerHTML=objtab.outerHTML;obj1.appendChild(obj2);obj1.appendChild(obj3);obj3.style.width=obj2.style.width=scrollwidth+'px';if(scrolltype==1||scrolltype==2){if(obj2.offsetHeight<scrollheight){var tabheight=scrollheight-obj2.offsetHeight;var tabmarginleft=(obj2.offsetWidth>scrollwidth)?scrollwidth:(obj2.offsetWidth+scrollwidth)/2;if(tabheight<0){tabheight=0;}else{obj2.innerHTML+="<table border=0 style='border:0px solid #ff0000;margin-left:"+tabmarginleft+"px;' cellpadding='0' cellspacing='0'><tr><td style='height:"+tabheight+"px;' nowrap></td></tr></table>";}}};document.write("<style type=\"text/css\">#"+element+"{overflow:hidden;width:"+scrollwidth+"px;}; #"+element+" #"+obj2.id+",#"+element+" #"+obj3.id+"{padding:0px !important;padding:0px;margin:0px !important;margin:0px;float:none;}; #"+obj2.id+" img,#"+obj3.id+" img{margin-right:"+scrollwspace+"px;};</style>");if(scrolltype==3||scrolltype==4){obj1.style.whiteSpace="nowrap";obj2.style.display="inline";var tabwidth=scrollwidth-obj2.offsetWidth;var tabmargintop=(obj2.offsetHeight>scrollheight)?scrollheight:(obj2.offsetHeight+scrollheight)/2;if(tabwidth<0){tabwidth=0;}else{obj2.innerHTML+="<table border=0 style='display:inline;margin-top:"+tabmargintop+"px;' cellpadding='0' cellspacing='0'><tr><td style='width:"+tabwidth+"px;' nowrap></td></tr></table>";}};obj3.innerHTML=obj2.innerHTML;Marquee.prototype.marqueeScrollTop=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj1=document.getElementById(element);var obj2=document.getElementById(element+"obj2");var obj3=document.getElementById(element+"obj3");if(obj2.offsetHeight>scrollheight)if(obj3.offsetTop-obj1.scrollTop<=0){obj1.scrollTop-=obj3.offsetTop;}else{var oldScrollTop=obj1.scrollTop;obj1.scrollTop++;if(oldScrollTop==obj1.scrollTop){obj1.scrollTop=0;}}else{if(scrollheight-obj1.scrollTop<=0){obj1.scrollTop-=scrollheight;}else{obj1.scrollTop++;}}};Marquee.prototype.marqueeScrollDown=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj1=document.getElementById(element);var obj2=document.getElementById(element+"obj2");var obj3=document.getElementById(element+"obj3");if(document.all){if(obj2.offsetTop-obj1.scrollTop>=0){obj1.scrollTop+=obj3.offsetHeight;}else{obj1.scrollTop--;}}else{if(obj2.offsetTop-obj1.scrollTop-obj2.offsetTop>=0){obj1.scrollTop+=obj3.offsetHeight;}else{obj1.scrollTop--;}}};Marquee.prototype.marqueeScrollLeft=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj1=document.getElementById(element);var obj2=document.getElementById(element+"obj2");var obj3=document.getElementById(element+"obj3");if(obj3.offsetWidth-obj1.scrollLeft<=0){obj1.scrollLeft-=obj2.offsetWidth;}else{obj1.scrollLeft++;}};Marquee.prototype.marqueeScrollRight=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj1=document.getElementById(element);var obj2=document.getElementById(element+"obj2");var obj3=document.getElementById(element+"obj3");if(obj1.scrollLeft<=0){obj1.scrollLeft+=obj3.offsetWidth;}else{obj1.scrollLeft--;}};var count;Marquee.prototype.marqueeStart=function(element,scrolltype,scrollwidth,scrollheight,speed){switch(scrolltype){case 1:if(Marquee.prototype.scrollTopOrDown(element,scrolltype,scrollwidth,scrollheight,speed)){Marquee.prototype.clearInterval(element);count=window.setInterval(Marquee.prototype.marqueeScrollTop.bind(this,element,scrolltype,scrollwidth,scrollheight,speed),speed);MarqueeInterval[element]=count;};break;case 2:if(Marquee.prototype.scrollTopOrDown(element,scrolltype,scrollwidth,scrollheight,speed)){Marquee.prototype.clearInterval(element);count=window.setInterval(Marquee.prototype.marqueeScrollDown.bind(this,element,scrolltype,scrollwidth,scrollheight,speed),speed);MarqueeInterval[element]=count;};break;case 3:Marquee.prototype.scrollLeftOrRight(element,scrolltype,scrollwidth,scrollheight,speed);Marquee.prototype.clearInterval(element);count=window.setInterval(Marquee.prototype.marqueeScrollLeft.bind(this,element,scrolltype,scrollwidth,scrollheight,speed),speed);MarqueeInterval[element]=count;break;case 4:Marquee.prototype.scrollLeftOrRight(element,scrolltype,scrollwidth,scrollheight,speed);Marquee.prototype.clearInterval(element);count=window.setInterval(Marquee.prototype.marqueeScrollRight.bind(this,element,scrolltype,scrollwidth,scrollheight,speed),speed);MarqueeInterval[element]=count;break;}};Marquee.prototype.scrollLeftOrRight=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj3=document.getElementById(element+"obj3");obj3.style.display="inline";};Marquee.prototype.scrollTopOrDown=function(element,scrolltype,scrollwidth,scrollheight,speed){var obj2=document.getElementById(element+"obj2");if(scrollwidth-obj2.offsetWidth<0){return true;}else{obj2.style.display="block";return true;}};Marquee.prototype.clearInterval=function(element){var interval;for(var key in MarqueeInterval){if(key==element){interval=MarqueeInterval[key];break;}};window.clearInterval(interval);};obj1.onmouseover=function(){Marquee.prototype.clearInterval(element);};obj1.onmouseout=function(){Marquee.prototype.marqueeStart(element,scrolltype,scrollwidth,scrollheight,speed);};Marquee.prototype.marqueeStart(element,scrolltype,scrollwidth,scrollheight,speed);};var MarqueeInterval=new Object();if((!/*@cc_on!@*/0)&&!window.opera){HTMLElement.prototype.__defineGetter__("outerHTML",function(){var a=this.attributes,str="<"+this.tagName,i=0;for(;i<a.length;i++)if(a[i].specified)str+=" "+a[i].name+'="'+a[i].value+'"';if(!this.canHaveChildren)return str+" />";return str+">"+this.innerHTML+"</"+this.tagName+">";});HTMLElement.prototype.__defineSetter__("outerHTML",function(s){var r=this.ownerDocument.createRange();r.setStartBefore(this);var df=r.createContextualFragment(s);this.parentNode.replaceChild(df,this);return s;});HTMLElement.prototype.__defineGetter__("canHaveChildren",function(){return !/^(area|base|basefont|col|frame|hr|img|br|input|isindex|link|meta|param)$/.test(this.tagName.toLowerCase());});};function GetImageSize(oImage){var OriginImage=new Image();if(OriginImage.src!=oImage.src)OriginImage.src=oImage.src;return{"width":OriginImage.width,"height":OriginImage.height};};(function(){var path,t=document.getElementsByTagName('script');t=t[t.length-1].src.replace(/\\/g,'/');path=(t.lastIndexOf('/')<0)?'.':t.substring(0,t.lastIndexOf('/'));var load=function(o,y,n,c){this.options=o;if(o.id&&document.getElementById(o.id))return;if(o.parent){o.parent=false;try{window.top.artDialog(o,y,n,c);return;}catch(e){};};var i=newBox().html(o.title||I18n.dialogDefaultTip,o.url||'about:blank',o.content,y,n,o.yesText||I18n.dialogOKButton,o.noText||I18n.dialogCancelButton,o.style||'',c,o.time,o.id,o.arguments).align(o.width||'auto',o.height||'auto',o.left||'center',o.top||'center',o.fixed,o.lock);return i;},art,boxs=[],onmouse=false,dom=document.documentElement||document.body,IE=!+'\v1',IE6=IE&&navigator.userAgent.indexOf("MSIE 6")!=-1,ie6PngRepair=false,Each=function(a,b){for(var i=0,len=a.length;i<len;i++)b(a[i],i);},C={x:0,y:0,t:0,l:0,w:0,h:0,st:0,sl:0,ddw:0,ddh:0,dbw:0,dbh:0,ml:0,mt:0},z=999999999,hideId='artDialogTemp',pageLock=0,winLoad=function(fn){var oldonload=window.onload;if(typeof window.onload!='function'){window.onload=fn;}else{window.onload=function(){if(oldonload){oldonload();};fn();};};},$ce=function(name){return document.createElement(name);},$ctn=function(txt){return document.createTextNode(txt);},hasClass=function(element,className){var reg=new RegExp('(\\s|^)'+className+'(\\s|$)');return element.className.match(reg);},addClass=function(element,className){if(!hasClass(element,className)){element.className+=' '+className;};},removeClass=function(element,className){if(hasClass(element,className)){var reg=new RegExp('(\\s|^)'+className+'(\\s|$)');element.className=element.className.replace(reg,' ');};},getClass=function(element,attribute){return element.currentStyle?element.currentStyle[attribute]:document.defaultView.getComputedStyle(element,false)[attribute];},addStyle=function(css){document.write('<style type="text/css">'+css+'</style>');},cmd=function(evt,x){var e=evt||window.event;onmouse=true;art=this;art.zIndex();C.x=e.clientX;C.y=e.clientY;C.t=parseInt(this.target.style.top);C.l=parseInt(this.target.style.left);C.w=this.target.clientWidth;C.h=this.target.clientHeight;C.ddw=dom.clientWidth;C.ddh=dom.clientHeight;C.dbw=Math.max(dom.clientWidth,dom.scrollWidth);C.dbh=Math.max(dom.clientHeight,dom.scrollHeight);C.sl=dom.scrollLeft;C.st=dom.scrollTop;if(getClass(art.target,'position')=='fixed'||getClass(art.target,'fixed')=='true'){C.ml=C.ddw-C.w;C.mt=C.ddh-C.h;}else{C.ml=C.dbw-C.w;C.mt=C.dbh-C.h;};if(x){document.onmousemove=function(a){resize.call(art,a,x);};}else{document.onmousemove=function(a){drag.call(art,a);};};document.onmouseup=function(){onmouse=false;document.onmouseup=null;if(document.body.releaseCapture)art.target.releaseCapture();};if(document.body.setCapture){art.target.setCapture();art.target.onmousewheel=function(){window.scrollTo(0,document.documentElement.scrollTop-window.event.wheelDelta/4);};};},drag=function(a){if(onmouse===false)return false;var e=a||window.event,_x=e.clientX,_y=e.clientY,_l=parseInt(C.l-C.x+_x-C.sl+dom.scrollLeft),_t=parseInt(C.t-C.y+_y-C.st+dom.scrollTop);if(_l>C.ml)_l=C.ml;if(_t>C.mt)_t=C.mt;if(_l<0)_l=0;if(_t<0)_t=0;art.target.style.left=_l+'px';art.target.style.top=_t+'px';return false;},resize=function(a,x){if(onmouse===false)return false;var e=a||window.event,_x=e.clientX,_y=e.clientY,_w=C.w+_x-C.x+x.w,_h=C.h+_y-C.y+x.h;if(_w>0)x.obj.style.width=_w+'px';if(_h>0)x.obj.style.height=_h+'px';return false;},newBox=function(){var j=-1;var ui_title_wrap=$ce('td');var ui_title=$ce('div');var ui_title_text=$ce('div');var ui_min=$ce('a');var ui_max=$ce('a');var ui_close=$ce('a');ui_title_wrap.className='ui_title_wrap';ui_title.className='ui_title';ui_title_text.className='ui_title_text';ui_min.className='ui_min';ui_min.href='javascript:void(0)';ui_min.appendChild($ctn('-'));ui_max.className='ui_max';ui_max.href='javascript:void(0)';ui_max.appendChild($ctn("口"));ui_close.className='ui_close';ui_close.href='javascript:void(0)';ui_close.appendChild($ctn('×'));ui_title.appendChild(ui_title_text);ui_title.appendChild(ui_min);ui_title.appendChild(ui_max);ui_title.appendChild(ui_close);ui_title_wrap.appendChild(ui_title);var ui_content_wrap=$ce('td');var ui_content=$ce('div');ui_content_wrap.className='ui_content_wrap';ui_content.className='ui_content';ui_content_wrap.appendChild(ui_content);var yesBtn=$ce('button'),yesWrap=$ce('span'),noBtn=$ce('button'),noWrap=$ce('span');yesWrap.className='ui_yes';noWrap.className='ui_no';var ui_bottom_wrap=$ce('td');var ui_bottom=$ce('div');var ui_btns=$ce('div');var ui_resize=$ce('div');ui_bottom_wrap.className='ui_bottom_wrap';ui_bottom.className='ui_bottom';ui_btns.className='ui_btns';ui_resize.className='ui_resize';ui_bottom.appendChild(ui_btns);ui_bottom.appendChild(ui_resize);ui_bottom_wrap.appendChild(ui_bottom);var ui_dialog_main=$ce('table');var cTbody=$ce('tbody');ui_dialog_main.className='ui_dialog_main';for(var r=0;r<3;r++){_tr=$ce('tr');if(r==0)_tr.appendChild(ui_title_wrap);if(r==1)_tr.appendChild(ui_content_wrap);if(r==2)_tr.appendChild(ui_bottom_wrap);cTbody.appendChild(_tr);};ui_dialog_main.appendChild(cTbody);var bTable=$ce('table');var bTbody=$ce('tbody');for(var r=0;r<3;r++){_tr=$ce('tr');for(var d=0;d<3;d++){_td=$ce('td');if(r==1&&d==1){_td.appendChild(ui_dialog_main);}else{_td.className='ui_border r'+r+'d'+d;};_tr.appendChild(_td);};bTbody.appendChild(_tr);};bTable.appendChild(bTbody);var ui_dialog=$ce('div');ui_dialog.className='ui_dialog';ui_dialog.appendChild(bTable);if(IE6){var ui_ie6_select_mask=$ce('iframe');ui_ie6_select_mask.className='ui_ie6_select_mask';ui_dialog.appendChild(ui_ie6_select_mask);};var ui_overlay=$ce('div');ui_overlay.className='ui_overlay';ui_overlay.appendChild($ce('div'));var ui_dialog_wrap=$ce('div');ui_dialog_wrap.className='ui_dialog_wrap';ui_dialog_wrap.appendChild(ui_dialog);ui_dialog_wrap.style.zIndex=++z;var $={};$.target=ui_dialog;$.target.style.zIndex=++z;$.zIndex=function(o){var x=o?o:ui_dialog;x.style.zIndex=++z;if(IE6)ui_dialog_wrap.style.zIndex=++z;return $;};var closeFn=null;$.close=function(f){if(f){closeFn=f;return $;};onmouse=false;$.free=true;function _close(){if(ie6PngRepair){ui_dialog_wrap.parentNode.removeChild(ui_dialog_wrap);$.free=false;return false;};ui_dialog.style.cssText=ui_title_text.innerHTML=ui_content.innerHTML=ui_btns.innerHTML=ui_dialog_wrap.id=ui_content.id='';removeClass(ui_content,'ui_iframe');removeClass(ui_dialog_wrap,'ui_fixed');bTable.className='';if(closeFn){closeFn();closeFn=null;};};if(ui_dialog_wrap.className.indexOf('ui_lock')>-1){$.alpha(ui_overlay,1,function(){ui_overlay.style.cssText='';if(pageLock==1)removeClass(document.getElementsByTagName('html')[0],'ui_page_lock');pageLock--;removeClass(ui_dialog_wrap,'ui_lock');_close();});}else{_close();};var a=true;};$.time=function(t){setTimeout(function(){$.close();},1000*t);return $;};$.html=function(title,url,content,yesFn,noFn,yesText,noText,style,closeFn,time,id,arguments){ui_title_text.innerHTML='<span class="ui_title_icon"></span>'+title;if(id){ui_dialog_wrap.id=id;ui_content.id=id+'Content';};var _this=this;if(yesFn){yesBtn.innerHTML=yesText;noBtn.innerHTML=noText;yesWrap.appendChild(yesBtn);ui_btns.appendChild(yesWrap);if(noFn){noBtn.onclick=function(){var n=noFn();if(n==undefined||n)_this.close();};noWrap.appendChild(noBtn);ui_btns.appendChild(noWrap);}else{noFn=null;};yesBtn.onclick=function(){var y=yesFn();if(y==undefined||y)_this.close();};};if(content){ui_content.innerHTML='<span class="ui_dialog_icon"></span>'+content;}else{var f=$ce('iframe');if(id){f.id=id+'iframe';};f.setAttribute('frameborder','0',0);f.src=url;ui_content.appendChild(f);addClass(ui_content,'ui_iframe');var theArgs=arguments;var s=function(){f.style.visibility='visible';f.contentWindow.closeDialog=function(){_this.close();};f.contentWindow.dialogArguments=theArgs;};if(f.attachEvent){f.attachEvent('onload',function(){s();});}else{f.onload=function(){s();};};};bTable.className+=''+style;ui_dialog.style.visibility='visible';if(closeFn)$.close(closeFn);if(time)$.time(time);$.free=false;return $;};$.lock=function(){var h=document.getElementsByTagName('html')[0];addClass(h,'ui_page_lock');addClass(ui_dialog_wrap,'ui_lock');$.zIndex(ui_overlay);ui_dialog_wrap.appendChild(ui_overlay);ui_overlay.style.visibility='visible';pageLock++;$.alpha(ui_overlay,0);return $;};$.alpha=function(obj,start,fn,x){if(!x)i=start;s=0.5;s=(start==0)?s:-s;i+=s;if(obj.filters){obj.filters.alpha.opacity=i*100;}else{obj.style.opacity=i;};if(i>0&&i<1){setTimeout(function(){$.alpha(obj,start,fn,i)},5);}else if(fn){fn();};return $;};$.align=function(width,height,left,top,fixed,lock,c){if(parseInt(width)==width)width=width+'px';if(parseInt(height)==height)height=height+'px';ui_content_wrap.style.width=width;ui_content_wrap.style.height=height;var dd=document.documentElement;var db=document.body;C.l=0;C.t=0;C.w=ui_dialog.clientWidth;C.h=ui_dialog.clientHeight;C.ddw=dom.clientWidth;C.ddh=dom.clientHeight;C.dbw=Math.max(dom.clientWidth,dom.scrollWidth);C.dbh=Math.max(dom.clientHeight,dom.scrollHeight);C.sl=Math.max(dd.scrollLeft,db.scrollLeft);C.st=Math.max(dd.scrollTop,db.scrollTop);if(lock)fixed=true;var minX,minY,maxX,maxY,centerX,centerY;if(fixed){if(IE6)addClass(document.getElementsByTagName('html')[0],'ui_ie6_fixed');addClass(ui_dialog_wrap,'ui_fixed');minX=0;maxX=C.ddw-C.w;centerX=maxX/2;minY=0;maxY=C.ddh-C.h;var hc=C.ddh*0.382-C.h/2;centerY=(hc>0)?hc:maxY/2;}else{minX=C.sl;maxX=C.ddw+minX-C.w;centerX=maxX/2;minY=C.st;maxY=C.ddh+minY-C.h;var hc=C.ddh*0.382-C.h/2+minY;centerY=(hc>minY)?hc:(maxY+minY)/2;};if(left=='center'){C.l=centerX>0?centerX:0;}else if(left=='left'){C.l=minX;}else if(left=='right'){C.l=maxX;}else{if(fixed)left=left-C.sl;if(left<minX){left=left+C.w;}else if(left>maxX){left=left-C.w;};C.l=left;};if(top=='center'){C.t=centerY>0?centerY:0;}else if(top=='top'){C.t=minY;}else if(top=='bottom'){C.t=maxY;}else{if(fixed)top=top-C.st;if(top<minY){top=top+C.h;}else if(top>maxY){top=top-C.h;};C.t=top;};if(ui_dialog_wrap.id==hideId)C.l='-9999999';ui_dialog.style.left=C.l+'px';ui_dialog.style.top=C.t+'px';if(lock)$.lock();$.zIndex(ui_dialog);return $;};var isMin=false;$.min=function(maxl,maxt,maxw,maxh){var d=ui_dialog;var c=ui_content_wrap;if(!maxl)maxl=d.style.left;if(!maxt)maxt=d.style.top;if(!maxw)maxw=c.style.width;if(!maxh)maxh=c.style.height;var curHeight=parseInt(c.style.height)-parseInt(maxh)/10>0?parseInt(c.style.height)-parseInt(maxh)/10:0;var curleft=(parseInt(d.style.left)-parseInt(maxl)/5)>0?(parseInt(d.style.left)-parseInt(maxl)/5):0;var curtop=(parseInt(d.style.top)-parseInt(maxt)/5)>0?(parseInt(d.style.top)-parseInt(maxt)/5):0;var curWidth=(parseInt(c.style.width)-parseInt(maxw)/10)>200?(parseInt(c.style.width)-parseInt(maxw)/10):200;if(curHeight>0){setTimeout(function(){$.min(maxl,maxt,maxw,maxh)},2);c.style.height=curHeight+"px";c.style.width=curWidth+"px";d.style.left=curleft+"px";d.style.top=curtop+"px";}else{c.style.height="0px";c.style.width="200px";d.style.left="0px";d.style.top="0px";if(isMin==false){ui_max.onclick=function(){$.max(maxl,maxt,maxw,maxh)};};isMin=true;}};$.max=function(left,top,maxw,maxh){var d=ui_dialog;var c=ui_content_wrap;var curHeight=(parseInt(c.style.height)+parseInt(maxh)/10);var curWidth=(parseInt(c.style.width)+parseInt(maxw)/10);var curleft=(parseInt(d.style.left)+parseInt(left)/5)>parseInt(left)?parseInt(left):(parseInt(d.style.left)+parseInt(left)/5);var curtop=(parseInt(d.style.top)+parseInt(top)/5)>parseInt(top)?parseInt(top):(parseInt(d.style.top)+parseInt(top)/5);if(curHeight<parseInt(maxh)){setTimeout(function(){$.max(left,top,maxw,maxh)},5);c.style.height=curHeight+"px";if(curWidth<parseInt(maxw)){c.style.width=curWidth+"px";}else{c.style.width=maxw;};if(curleft<parseInt(left)){d.style.left=curleft+"px";}else{d.style.left=left;};if(curtop<parseInt(top)){d.style.top=curtop+"px";}else{d.style.top=top;}}else{c.style.height=maxh;c.style.width=maxw;d.style.left=left;d.style.top=top;isMin=false;}};Each([ui_title_text],function(o,i){o.onmousedown=function(a){cmd.call($,a,false);addClass(ui_dialog_wrap,'ui_move');};o.onmouseout=function(){removeClass(ui_dialog_wrap,'ui_move');};o.onselectstart=function(){return false;};});ui_resize.onmousedown=function(a){var d=ui_dialog;var c=ui_content_wrap;cmd.call($,a,{obj:c,w:c.clientWidth-d.clientWidth,h:c.clientHeight-d.clientHeight});};if(IE6){Each([yesWrap,noWrap],function(o,i){o.onmouseover=function(){addClass(o,'ui_hover');};o.onmouseout=function(){removeClass(o,'ui_hover');};});};ui_min.onclick=function(){$.min()};ui_close.onclick=function(){$.close()};document.onkeyup=function(evt){var e=evt||window.event;if(e.keyCode==27)$.close();};document.body.appendChild(ui_dialog_wrap);return $;};var artLayout='* html body{margin:0;}.ui_content{color:black;}.ui_title_icon,.ui_content,.ui_dialog_icon,.ui_btns span{display:inline-block;*zoom:1;*display:inline;}.ui_dialog{visibility:hidden;text-align:left;position:absolute;top:0;left:-99999em;_overflow:hidden;}.ui_dialog table{border:0;margin:0;border-collapse:collapse;}.ui_dialog td{padding:0;}.ui_title_icon{vertical-align:middle;}.ui_title_text{overflow:hidden;cursor:default;-moz-user-select:none;user-select:none;}.ui_close{display:block;position:absolute;outline:none;}.ui_content_wrap{height:auto;text-align:center;}.ui_content{margin:10px;text-align:left;}.ui_dialog_icon{vertical-align:middle;}.ui_content.ui_iframe{margin:0;*padding:0;display:block;height:100%;}.ui_iframe iframe{visibility:hidden;width:100%;height:100%;border:none;overflow:auto;}.ui_bottom{position:relative;}.ui_resize{position:absolute;right:0;bottom:0;z-index:1;cursor:nw-resize;_font-size:0;}.ui_btns{text-align:right;white-space:nowrap;}.ui_btns span{margin:5px 10px;}.ui_btns button{cursor:pointer;}.ui_overlay{visibility:hidden;position:absolute;top:0;left:0;width:100%;height:100%;filter:alpha(opacity=0);opacity:0;_overflow:hidden;}.ui_overlay div{height:100%;}* html .ui_ie6_select_mask{width:99999em;height:99999em;position:absolute;top:0;left:0;z-index:-1;}.ui_move .ui_title_text{cursor:move;}html >body .ui_dialog_wrap.ui_fixed .ui_dialog{position:fixed;}* html .ui_dialog_wrap.ui_fixed .ui_dialog{fixed:true;}* html.ui_ie6_fixed{background:url(*) fixed;}* html.ui_ie6_fixed body{height:100%;}* html .ui_dialog_wrap.ui_fixed{width:100%;height:100%;position:absolute;left:expression(documentElement.scrollLeft+documentElement.clientWidth-this.offsetWidth);top:expression(documentElement.scrollTop+documentElement.clientHeight-this.offsetHeight);}html.ui_page_lock >body{overflow:hidden;}* html.ui_page_lock{overflow:hidden;}* html.ui_page_lock select,* html.ui_page_lock .ui_ie6_select_mask{visibility:hidden;}html.ui_page_lock >body .ui_dialog_wrap.ui_lock{width:100%;height:100%;position:fixed;top:0;left:0;}';addStyle(artLayout);if(IE6){document.execCommand('BackgroundImageCache',false,true);ie6PngRepair=getClass(document.getElementsByTagName('html')[0],'ie6PngRepair')=='true'?true:false;if(ie6PngRepair){var script=$ce('script');script.src=path+'/iepngfix/iepngfix_tilebg.js';document.getElementsByTagName('head')[0].appendChild(script);addStyle('.ui_resize, .ui_ie6_select_mask { display:none; } td.ui_border, td.ui_title_wrap *, .ui_dialog_icon  { behavior: url("'+path+'/iepngfix/iepngfix.htc");}');};};window.artDialog=load;})();function _error_msg_show(msg,click,icon,title){click=click?click:' ';icon=icon?icon:'';title=title?title:I18n.dialogDefaultTip;artDialog({title:title,content:msg,style:icon,width:300,height:200},function(){eval(click)});};function _win_error_msg_show(msg,click,icon,title,width,height){click=click?click:' ';icon=icon?icon:'';title=title?title:I18n.dialogDefaultTip;width=width?width:300;height=height?height:200;artDialog({title:title,content:msg,style:icon,width:300,height:200,lock:true},function(){eval(click)});};function _confirm_msg_show(msg,click_ok,click_no,title){click_ok=click_ok?click_ok:' ';click_no=click_no?click_no:' ';title=title?title:I18n.dialogDefaultTip;artDialog({title:title,fixed:true,content:msg,style:icon,lock:true},function(){eval(click_ok)},function(){eval(click_no)});};function _win_confirm_msg_show(msg,click_ok,click_no,top,left,width,height){click_ok=click_ok?click_ok:' ';click_no=click_no?click_no:' ';title=I18n.dialogDefaultTip;artDialog({title:title,fixed:true,content:msg,width:width,height:height,lock:true},function(){eval(click_ok)},function(){eval(click_no)});};function showWindow(_sUrl,_sWidth,_sHeight,_sTitle,_sScroll,_login,id,_style){var oEdit;oEdit=artDialog({style:_style,id:id,title:_sTitle,url:_sUrl,width:_sWidth,height:_sHeight,lock:true});return oEdit;};function showTopWindow(_sUrl,_sWidth,_sHeight,_sTitle,id,_style){var oEdit;oEdit=artDialog({style:_style,id:id,title:_sTitle,url:_sUrl,width:_sWidth,height:_sHeight,parent:true,lock:true});return oEdit;};function showDialogWindow(options,callback){return artDialog(options,null,null,callback);};function dec(objstr){var parmeter=parseInt(eval(objstr));if(parmeter-5>0){eval(objstr)=(parmeter-5)+"px";setTimeout(dec('ui_content_wrap.style.height'),5);}else{eval(objstr)="0px";}};function asc(objstr,max){var parmeter=parseInt(eval(objstr));if(parmeter-5<max){eval(objstr)=(parmeter+5)+"px";}else{eval(objstr)=max+"px";}};function ADItemObj(){this.id=0;this.type=1;this.resHeight=100;this.resWidth=100;this.hint="";this.resURL="";this.linkURL="";this.power=1;this.text="";this.getHtml=getADItemHTML;};function getADItemHTML(){var str="";var name="ad_"+this.id;switch(this.type){case 1:str="<A TARGET='_blank' HREF='"+this.linkURL+"'><IMG ID='"+name+"' NAME='"+name+"' BORDER=0 HEIGHT=";str+=this.resHeight+" WIDTH="+this.resWidth+" SRC='"+this.resURL+"' title='"+this.hint+"' ALT='"+this.hint+"'></A>";break;case 2:str="<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000'  codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0' ";str+=" name='"+name+"' id='"+name+"'  width='"+this.resWidth+"' 	height='"+this.resHeight+"'>";str+="<param name='movie' value='"+this.resURL+"'>";str+="<param name='quality' value='autohigh'>";str+="<embed name='"+name+" id='"+name+"'  width='"+this.resWidth+"' height='"+this.resHeight+"' src='"+this.resURL+"'";str+=" quality='autohigh' pluginspage='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash' type='application/x-shockwave-flash'></embed>";str+="</object>";break;case 3:str="<div>"+this.text+"</div>";break;case 4:str="<script>"+this.text+"</script>";break;case 5:str="<IFRAME FRAMEBORDER=0 SCROLLING=NO FRAMESPACING=0 MAGINWIDTH=0 MARGINHEIGHT=0 HEIGHT=";str+=this.resHeight+" WIDTH="+this.resWidth+" SRC='"+this.resURL+"'></IFRAME>";};return str;};function ADFloatDIV(id){this.ID=id;this.divName="";this.status=true;this.virgin=true;this.adItems=new Array();this.currentAD=null;this.htmlDIV=null;this.floatType=1;this.divWidth=100;this.divHeight=100;this.left=-1;this.top=-1;this.dx=2*(Math.random()>0.5?1:-1);this.dy=1*(Math.random()>0.5?1:-1);this.counter=0;this.timer=null;this.step=1;this.rate=10;this.delay=3000;this.setADItem=Float_setADItem;this.adStart=adStart;this.showDIV=Float_showDIV;this.floatDIV=Float_floatDIV;this.pauseMove=Float_pauseMove;this.continueMove=Float_continueMove;this.divInvisible=Float_invisible;this.getCurrentAD=getRandomObj;this.initDiv=FLoat_InitDiv;this.popWindow=pop_window;};function adStart(){if(this.floatType<=10){this.showDIV();}else if(this.floatType>10){this.popWindow();}};function FLoat_InitDiv(){if(this.virgin==false)return;this.virgin=false;if(this.floatType==1||this.floatType==2||this.floatType==3||this.floatType==4){if(this.left<0){this.left=500+500*Math.random()*(Math.random()>0.5?1:-1);};if(this.top<0){this.top=300+300*Math.random()*(Math.random()>0.5?1:-1);}}else if(this.floatType==5||this.floatType==6){if(this.left==-1){this.left=(window.document.body.offsetWidth-this.divWidth)/2;}else if(this.left==-2){this.left=window.document.body.offsetWidth-this.divWidth;};var sHeight=document.documentElement.clientHeight||document.body.clientHeight;if(this.top==-1){this.top=(sHeight-this.divHeight-this.dy-22)/2;}else if(this.top==-2){this.top=sHeight-this.divHeight-this.dy*2-22;}};if(this.left>(window.document.body.offsetWidth-this.divWidth)){this.left=(window.document.body.offsetWidth-this.divWidth)/window.screen.width*this.left;if(this.left>(window.document.body.offsetWidth-this.divWidth)){this.left=(window.document.body.offsetWidth-this.divWidth);}};if(this.top>(window.document.body.offsetHeight-this.divHeight-this.dy*2-22)){this.top=(window.document.body.offsetHeight-this.divHeight-this.dy*2-22)/window.screen.width*this.top;if(this.top>(window.document.body.offsetHeight-this.divHeight-this.dy*2-22)){this.top=(window.document.body.offsetHeight-this.divHeight-this.dy*2-22);}}};function Float_floatDIV(){screenX=document.documentElement.scrollLeft||document.body.scrollLeft;screenY=document.documentElement.scrollTop||document.body.scrollTop;screenW=document.documentElement.clientWidth||document.body.clientWidth;screenW=screenW-this.divWidth;screenH=document.documentElement.clientHeight||document.body.clientHeight;screenH=screenH-this.divHeight-this.dy*2;this.initDiv();var theLeft,theTop;if(this.floatType==1){theLeft=this.left+this.dx*this.step;theTop=this.top+this.dy*this.step;if((theLeft>=screenW&&this.dx>0)||(theLeft<=0&&this.dx<0))this.dx=-1*this.dx;if((theTop>=screenH&&this.dy>0)||(theTop<=0&&this.dy<0))this.dy=-1*this.dy;}else if(this.floatType==2){if(this.counter>=(200/this.rate)){this.dx=(this.dx>0?1:-1)*Math.random()*5;this.dy=(this.dy>0?1:-1)*Math.random()*5;this.counter=0;};this.counter+=1;theLeft=this.left;theTop=this.top+this.dy*this.step;if((theLeft>=screenW&&this.dx>0)||(theLeft<=0&&this.dx<0))this.dx=-1*this.dx;if((theTop>=screenH&&this.dy>0)||(theTop<=0&&this.dy<0))this.dy=-1*this.dy;}else if(this.floatType==3){this.dx=0;theLeft=this.left+this.dx*this.step;theTop=this.top+this.dy*this.step;if((theLeft>=screenW)||(theLeft<=0)){this.left=this.left+this.currentAD.resWidth;};if((theTop>=screenH&&this.dy>0)||(theTop<=0&&this.dy<0))this.dy=-1*this.dy;}else if(this.floatType==4){this.dy=0;theLeft=this.left+this.dx*this.step;theTop=this.top+this.dy*this.step;if((theLeft<=0)){this.dx=-1*this.dx;};if((theLeft>=screenW&&this.dx>0)){this.dx=-1*this.dx;}}else if(this.floatType==5){this.dx=0;this.dy=0;}else if(this.floatType=6){if(document.all){this.htmlDIV.style.pixelLeft=this.left;this.htmlDIV.style.pixelTop=this.top;}else{this.htmlDIV.style.left=this.left+"px";this.htmlDIV.style.top=this.top+"px";};this.htmlDIV.timer=setTimeout(this.ID+".divInvisible()",this.delay);return;};this.left=this.left+this.dx*this.step;this.top=this.top+this.dy*this.step;if(document.all){this.htmlDIV.style.pixelLeft=this.left+screenX;this.htmlDIV.style.pixelTop=this.top+screenY;}else{this.htmlDIV.style.left=this.left+screenX+"px";this.htmlDIV.style.top=this.top+screenY+"px";};var	delay=80/this.rate;clearTimeout(this.htmlDIV.timer);this.htmlDIV.timer=setTimeout(this.ID+".floatDIV()",delay);};function Float_showDIV(){this.currentAD=this.getCurrentAD(this.adItems);this.divHeight=this.currentAD.resHeight;this.divWidth=this.currentAD.resWidth;if(this.currentAD==null||this.currentAD=="")return;this.divName="ADF_"+this.ID;this.divHeight=this.divHeight+22;var str="<DIV id='"+this.divName+"' onMouseOver='"+this.ID+".pauseMove()' onMouseOut='"+this.ID+".continueMove()";str+="' STYLE='position:absolute; visibility:visible; z-index:1; width:";if(document.all){str+=this.divWidth+"; height:"+this.divHeight+"; left:"+this.left+";top:"+this.top+"'>";}else{str+=this.divWidth+"; height:"+this.divHeight+"; left:"+this.left+"px;top:"+this.top+"px'>";};str+=this.currentAD.getHtml();str+="<span  STYLE='display:block;background-color:#ECE9D8;font-size:12px; width:30px; line-height:1.5;text-align:right;padding:2px;cousor:hand'  ><A HREF='javascript:"+this.ID+".divInvisible()'''>"+I18n.adClose+"</A>&nbsp;</span>";str+="</DIV>";document.write(str);this.htmlDIV=$(this.divName);this.floatDIV();};function Float_pauseMove(){clearTimeout(this.htmlDIV.timer);};function Float_continueMove(){if(this.status)this.floatDIV();};function Float_setADItem(ItemObj){var thisLine=this.adItems.length;this.adItems[thisLine]=new Array(ItemObj,ItemObj.power);};function Float_invisible(){clearTimeout(this.htmlDIV.timer);this.htmlDIV.style.visibility="hidden";this.status=false;};function pop_window(){var popC=getCookie("_cmsPopAD");if(popC&&popC>0){return;};this.currentAD=this.getCurrentAD(this.adItems);this.divHeight=this.currentAD.resHeight;this.divWidth=this.currentAD.resWidth;if(this.currentAD==null||this.currentAD=="")return;var str="width="+this.divWidth+"px,height="+this.divHeight+"px,toolbar=0,location=0,status=0,menubar=0,scrollbars=0,resizable=0,";str+="Top="+this.top+",Left="+this.left;var url="http://"+window.location.host+_contextPath+"/cad?_cmsADC="+this.currentAD.id;if(this.floatType==11){window.open(url,"",str);}else if(this.floatType==12){window.open(url,"",str);window.focus();}else if(this.floatType==13){if(browser.isNS){window.open(url,"","modal=yes,"+str);}else{if(browser.isIE7){str="dialogWidth:"+this.divWidth+"px;dialogHeight:"+this.divHeight+"px;dialogLeft:"+this.left+"px;dialogTop:"+this.top+"px;";}else if(browser.isIE){str="dialogWidth:"+(this.divWidth+6)+"px;dialogHeight:"+(this.divHeight+56)+"px;dialogLeft:"+this.left+"px;dialogTop:"+this.top+"px;";}else{str="dialogWidth:"+this.divWidth+"px;dialogHeight:"+this.divHeight+"px;dialogLeft:"+this.left+"px;dialogTop:"+this.top+"px;";};window.showModalDialog(url,window,str);}};setCookie("_cmsPopAD",this.delay,this.delay);};function getRandomObj(array){var totalPower=0;var start=0;for(ii=0;ii<array.length;ii++){totalPower+=array[ii][1];array[ii][2]=start;array[ii][3]=start+array[ii][1];start=array[ii][3];};var theSelected=Math.random()*totalPower;var counter=0;for(ii=0;ii<array.length;ii++){if(theSelected>array[ii][2]&&theSelected<array[ii][3]){return array[ii][0];}}};function staticADDIV(id){this.ID=id;this.adItems=new Array();this.currentAD=null;this.setADItem=static_setADItem;this.setHtml=positionADHTML;this.getCurrentAD=getRandomObj;};function positionADHTML(divName){var divObj=$(divName);this.currentAD=this.getCurrentAD(this.adItems);var str=this.currentAD.getHtml();divObj.innerHTML=str;};function static_setADItem(ItemObj){var thisLine=this.adItems.length;this.adItems[thisLine]=new Array(ItemObj,ItemObj.power);};var Ajax={getTransport:getHttpRequestObject,activeRequestCount:0,RequestEvents:['Uninitialized','Loading','Loaded','Interactive','Complete']};Ajax.Request=function(url,options){this.transport=Ajax.getTransport();this.options={method:'post',asynchronous:true,contentType:'application/x-www-form-urlencoded',encoding:'UTF-8',parameters:'',onSuccess:function(){},onFailure:function(){},onException:function(){}};for(var p in options){this.options[p]=options[p];};this.options.method=this.options.method.toLowerCase();this.onSuccess=this.options.onSuccess;this.onFailure=this.options.onFailure;this.request(url);};Ajax.Request.prototype.request=function(url){this.url=url;this.method=this.options.method;var param;if(typeof this.options.parameters!='string'){param=Form.Methods.toQueryString(this.options.parameters);}else{param=this.options.parameters;};if(this.method=='get'&&param!=null&&param!=''){this.url+=((this.url.indexOf('?')>-1)?'&':'?')+param;};try{this.transport.open(this.method.toUpperCase(),this.url,this.options.asynchronous);if(this.options.asynchronous)setTimeout(function(){this.respondToReadyState(1)}.bind(this),10);this.transport.onreadystatechange=this.onStateChange.bind(this);this.setRequestHeaders();this.body=this.method=='post'?(this.options.postBody||param):null;this.transport.send(this.body);if(!this.options.asynchronous&&this.transport.overrideMimeType)this.onStateChange();}catch(e){this.dispatchException(e);}};Ajax.Request.prototype.onStateChange=function(){var readyState=this.transport.readyState;if(readyState>1&&!((readyState==4)&&this._complete))this.respondToReadyState(this.transport.readyState);};Ajax.Request.prototype.respondToReadyState=function(readyState){var state=Ajax.RequestEvents[readyState];var transport=this.transport;if(state=='Complete'){try{this._complete=true;this.options['on'+(this.success()?'Success':'Failure')](transport);}catch(e){this.dispatchException(e);}};if(state=='Complete'){this.transport.onreadystatechange=function(){};}};Ajax.Request.prototype.success=function(){return !this.transport.status||(this.transport.status>=200&&this.transport.status<300);};Ajax.Request.prototype.setRequestHeaders=function(){var headers={'X-Requested-With':'XMLHttpRequest','Accept':'text/javascript, text/html, application/xml, text/xml, */*'};if(this.method=='post'){headers['Content-type']=this.options.contentType+(this.options.encoding?'; charset='+this.options.encoding:'');if(this.transport.overrideMimeType&&(navigator.userAgent.match(/Gecko\/(\d{4})/)||[0,2005])[1]<2005)headers['Connection']='close';};for(var name in headers)this.transport.setRequestHeader(name,headers[name]);};Ajax.Request.prototype.dispatchException=function(exception){(this.options.onException||function(){})(this,exception);};function getVisitCount(url,type,visitID){new Ajax.Request(url,{method:'get',onSuccess:function(transport){var xmldoc=transport.responseXML;var root=xmldoc.getElementsByTagName('root')[0];var status_node=root.getElementsByTagName('status')[0];var status=status_node.firstChild.data;var msg_node=root.getElementsByTagName('message')[0];var msg=msg_node.firstChild.data;if(status=="0"){buildVisitCountStyle(msg,type,visitID);}else{buildVisitCountStyle("888888",type,visitID);}}});};function buildVisitCountStyle(count,type,visitID){if(!type){type="NORMAL";};if(!visitID){visitID="visitCount";};if(type=="IMAGE"){var prefix="<img class=\"counterImg\" src=\"img/counter_";var suffix=".gif\">";var result=[];for(var i=0;i<count.length;i++){result.push(prefix);result.push(count.charAt(i));result.push(suffix);};$(visitID).outerHTML=result.join('');}else{$(visitID).outerHTML=count;}};var request={__paraMap__:(new function(){var paraStr=location.search.substring(1),paras=paraStr.split("&"),paraMap={};for(var i=0,l=paras.length;i<l;i++){var paraSplit=paras[i].split(/=/),key=paraSplit[0],value=paraSplit[1];paraMap[key]=value;};return paraMap;}),get:function(name){return this.__paraMap__[name];},set:function(name,value){this.__paraMap__[name]=value;},getUrl:function(){var result=location.pathname+"?";var count=0;for(var k in this.__paraMap__){if(count>0)result+="&";if(!k||k=="")continue;result+=k+"="+this.__paraMap__[k];count++;};return result;}};



