function is_numeric(A){return(typeof (A)=="number")}function is_string(A){return(typeof (A)=="string")}function is_object(A){return(typeof (A)=="object")}function is_null(A){return A==null}function empty(B){var A=false;if(typeof (B)=="number"&&(B==0||isNaN(B))){A=true}else{if(typeof (B)=="string"&&B==""){A=true}else{if(typeof (B)=="object"&&B==null){A=true}}}return A}function trim(B){if(is_string(B)&&B!=""){var C=0;var A=B.length;while(C<B.length&&(B[C]==" "||B[C]=="\r"||B[C]=="\n"||B[C]=="\t")){C++}while(A>0&&(B[A-1]==" "||B[A-1]=="\r"||B[A-1]=="\n"||B[A-1]=="\t")){A--}if(C<A){return B.substring(C,A)}}return""}function str_replace(A,F,E){if(typeof (A)=="string"&&A!=""&&typeof (F)=="string"&&F!=""&&typeof (E)=="string"&&E!=F){var B=0;var D=F.length;var C=E.length;while((B=A.indexOf(F,B))>=0){A=A.substr(0,B)+E+A.substr(B+D,A.length-B-D);B+=C}return A}return""}function InformeObject(){this.id="";this.bind=function(){if(typeof (document.informe_objects)!="object"||document.informe_objects==null){document.informe_objects=new Object()}do{this.id="infob"+Math.floor(1000000*Math.random())}while(typeof (document.informe_objects[this.id])=="object"&&document.informe_objects[this.id]!=null);document.informe_objects[this.id]=this};this.getBindPath=function(){return"document.informe_objects."+this.id};this.getObjectById=function(A){if(is_string(A)&&A!=""){if(typeof (document.informe_objects)!="object"||document.informe_objects==null){document.informe_objects=new Object()}if(typeof (document.informe_objects[A])=="object"&&document.informe_objects[A]!=null){return document.informe_objects[A]}}return null}}function numericFilter(C){if(typeof (C)=="object"&&C!=null){var B="";var D=false;for(var A=0;A<C.value.length;A++){if(C.value[A]>"9"||C.value[A]<"0"){D=true}else{B+=C.value[A]}}if(D){C.value=B}}}function onBlurNumericFilter(D,C){if(typeof (D)=="object"&&D!=null){var B="";var E=false;for(var A=0;A<D.value.length;A++){if(D.value[A]>"9"||D.value[A]<"0"){E=true}else{B+=D.value[A]}}if(E||B==""||B=="0"){D.value=(B==""||B=="0"?C:B)}}}function InformeVideo(){this.window=false;this.container=false;this.saveField=false;this.parentConstrunct=InformeObject;this.parentConstrunct();this.bind();this.logoPath="/common/style/img/logos/";this.videoSystems=new Array();this.videoSystems[0]=new Object();this.videoSystems[0].name="youtube";this.videoSystems[0].title="YouTube";this.videoSystems[0].url="www.youtube.com";this.videoSystems[0].logo="youtube.png";this.videoSystems[1]=new Object();this.videoSystems[1].name="yahoo";this.videoSystems[1].title="Yahoo Video";this.videoSystems[1].url="video.yahoo.com";this.videoSystems[1].logo="yahoo.png";this.videoSystems[2]=new Object();this.videoSystems[2].name="metacafe";this.videoSystems[2].title="Metacafe";this.videoSystems[2].url="www.metacafe.com";this.videoSystems[2].logo="metacafe.png";this.videoSystems[3]=new Object();this.videoSystems[3].name="msn";this.videoSystems[3].title="MSN Video";this.videoSystems[3].url="video.msn.com";this.videoSystems[3].logo="msn.png";this.videoSystems[4]=new Object();this.videoSystems[4].name="rambler";this.videoSystems[4].title="Rambler Vision";this.videoSystems[4].url="vision.rambler.ru";this.videoSystems[4].logo="rambler.png";this.videoSystems[5]=new Object();this.videoSystems[5].name="reuters";this.videoSystems[5].title="Reuters";this.videoSystems[5].url="www.reuters.com/news/video";this.videoSystems[5].logo="reuters.png";this.videoSystems[6]=new Object();this.videoSystems[6].name="rutube";this.videoSystems[6].title="Ru Tube";this.videoSystems[6].url="rutube.ru";this.videoSystems[6].logo="rutube.png";this.videoSystems[7]=new Object();this.videoSystems[7].name="myspace";this.videoSystems[7].title="MySpace";this.videoSystems[7].url="myspacetv.com";this.videoSystems[7].logo="myspace.png";this.videoSystems[8]=new Object();this.videoSystems[8].name="mailru";this.videoSystems[8].title="Video Mail.Ru";this.videoSystems[8].url="video.mail.ru";this.videoSystems[8].logo="mail_ru.png";this.videoSystems[9]=new Object();this.videoSystems[9].name="tutv";this.videoSystems[9].title="Tu TV";this.videoSystems[9].url="tu.tv";this.videoSystems[9].logo="tutv.png";this.videoSystems[10]=new Object();this.videoSystems[10].name='smotri';this.videoSystems[10].title='Smotri Com';this.videoSystems[10].url='smotri.com';this.videoSystems[10].logo='smotri.jpg';this.initContainer=function(){if(typeof (this.window)=="object"&&this.window!=null){this.container=this.window.getContainer();return(typeof (this.container)=="object"&&this.container!=null)}return false};this.show=function(){if(typeof (this.container)!="object"||this.container==null){this.initContainer()}if(typeof (this.container)=="object"&&this.container!=null){this.window.setTitle("Video adding");this.container.innerHTML='<form name="form_'+this.id+'" onsumbit="return false;">\n<table border="0" width="100%" height="370px">\n <tr>\n  <td colspan="2" align="center"><div class="iwin-scrolled" id="video-sys-list"></div>\n  </td>\n </tr>\n <tr>\n  <td class="iwin-text" width="40px" style="text-align: right;">URL:</td>\n  <td class="iwin-text">\n   <input class="iwin-input" type="text" name="url" value="" style="width: 350px;" title="URL of the page with video"><br /><small>please fill this field with a link to the page with video</small>\n  </td>\n </tr>\n <tr>\n  <td colspan="2" class="iwin-text" style="text-align: center;">\n   W:<input class="iwin-input" type="text" name="width"  value="400" style="width: 40px;" title="The Width of your video object at the post" maxlength="4" onKeyUp="numericFilter(this);" onKeyPress="numericFilter(this);" onKeyup="numericFilter(this);" onBlur="onBlurNumericFilter(this, 400);" />px\n   H:<input class="iwin-input" type="text" name="height" value="300" style="width: 40px;" title="The Height of your video object at the post" maxlength="4" onKeyUp="numericFilter(this);" onKeyPress="numericFilter(this);" onKeyup="numericFilter(this);" onBlur="onBlurNumericFilter(this, 300);" />px\n  </td>\n </tr>\n <tr>\n  <td colspan="2" style="text-align: center;">\n   <input class="iwin-button" type="button" value="Set" onClick="'+this.getBindPath()+'.save();" />\n   <input class="iwin-button" type="button" value="Cancel" onClick="'+this.getBindPath()+'.cancel();" />\n  </td>\n </tr>\n</table>\n</form>\n';setTimeout(this.getBindPath()+".showVideoSystems();",200)}};this.showVideoSystems=function(){var C=document.getElementById("video-sys-list");if(typeof (C)=="object"&&C!=null){var B='<table border="0">\n';for(var A=0;A<this.videoSystems.length;A++){B+=' <tr>\n  <td><input type="radio" name="systemId" id="check_'+this.id+"_"+A+'" value='+A+'></td>\n  <td><div class="ivideo-sys-name"><label for="check_'+this.id+"_"+A+'">'+this.videoSystems[A].title+'</label></div></td>\n  <td><a href="http://'+this.videoSystems[A].url+'" target="_blank" class="ivideo-sys-name"><img src="'+this.logoPath+this.videoSystems[A].logo+'" border="0" /></a></td>\n </tr>\n'}B+="</table>\n";C.innerHTML=B}};this.save=function(){var H=false;if(typeof (document.forms["form_"+this.id])=="object"&&document.forms["form_"+this.id]!=null){var G=document.forms["form_"+this.id];var B=false;var C=G.elements.url.value;var E=G.elements.width.value;var A=G.elements.height.value;H=true;for(var D=0;D<G.elements.systemId.length;D++){if(G.elements.systemId[D].checked){B=Math.floor(G.elements.systemId[D].value)}}if(typeof (B)!="number"||isNaN(B)||B<0||B>=this.videoSystems.length){H=false;alert("You haven't selected video system, please do it.")}if(H&&C==""){H=false;alert("You haven't set URL of the page with video, please do it.")}else{/*if(H&&(C.indexOf("http://"+this.videoSystems[B].url)<0||C.length<15)){H=false;alert("Sorry, but you've entered a wrong URL of the page with video, please enter a valid URL.")}*/}if(H&&typeof (this.saveField)=="object"&&this.saveField!=null){var F="[video="+this.videoSystems[B].name+","+E+","+A+"]"+C+"[/video]";if(typeof (this.saveField.value)=="string"){this.saveField.value+=F}else{if(typeof (this.saveField.innerHTML)=="string"){this.saveField.innerHTML+=F}}}}if(H&&typeof (this.window)=="object"&&this.window!=null){this.window.hide()}};this.cancel=function(){if(typeof (this.window)=="object"&&this.window!=null){this.window.hide()}}}function InformeWindow(){this.container=false;this.title="";this.state=0;this.parentConstrunct=InformeObject;this.parentConstrunct();this.bind();this.initContainer=function(){if(typeof (this.container)!="object"||this.container==null){this.container=document.createElement("DIV");this.container.className="iwindow";this.container.innerHTML='   <div class="iwin-title">\n    <div class="iwin-title-left"></div>\n    <div class="iwin-center" id="iwin-title-field">'+this.title+'</div>\n    <div class="iwin-title-right"></div>\n   </div>\n   <div class="iwin-body" id="iwin-body-'+this.id+'">\n   </div>\n   <div class="iwin-foot">\n    <div class="iwin-foot-left"></div>\n    <div class="iwin-foot-center"></div>\n    <div class="iwin-foot-right"></div>\n   </div>'}};this.getContainer=function(){if(this.state==1){return document.getElementById("iwin-body-"+this.id)}return null};this.show=function(){if(typeof (this.container)!="object"||this.container==null){this.initContainer();this.state=0}if(this.state==0&&typeof (this.container)=="object"&&this.container!=null){document.body.appendChild(this.container);this.container.style.visibility="visible";this.state=1;this.alignPosition()}};this.alignPosition=function(){if(this.state==1){var A=document.body.clientWidth;var B=document.body.clientHeight;A-=(typeof (this.container.offsetWidth)=="number"&&!isNaN(this.container.offsetWidth)?this.container.offsetWidth:300);B-=(typeof (this.container.offsetHeight)=="number"&&!isNaN(this.container.offsetHeight)?this.container.offsetHeight:300);if(A<0){A=0}if(B<0){B=0}A=Math.floor(A/2);B=Math.floor(B/2);if(typeof (document.body.scrollLeft)=="number"&&!isNaN(document.body.scrollLeft)){A+=document.body.scrollLeft;B+=document.body.scrollTop}if(this.container.offsetLeft!=A){this.container.style.left=A+"px"}if(this.container.offsetTop!=B){this.container.style.top=B+"px"}setTimeout(this.getBindPath()+".alignPosition();",100)}};this.hide=function(){if(this.state==1&&typeof (this.container)=="object"&&this.container!=null){var A=false;if(typeof (this.container.parentNode)=="object"&&this.container.parentNode!=null){A=this.container.parentNode}else{if(typeof (this.container.parentElement)=="object"&&this.container.parentElement!=null){A=this.container.parentElement}}if(typeof (A)=="object"&&A!=null){A.removeChild(this.container);this.state=0}}else{this.state=0}};this.setTitle=function(A){if(is_string(A)){this.title=A;if(this.state==1){var B=document.getElementById("iwin-title-field");if(typeof (B)=="object"&&B!=null){B.innerHTML=A}}}}}function popup(C,D,A,B){if(!B){B="_popup"}window.open(C.replace(/&amp;/g,"&"),B,"height="+A+",resizable=yes,scrollbars=yes, width="+D);return false}function jumpto(){var E=prompt(jump_page,on_page);var C=".html";var A=".htm";var B="/";var D="-";if(E!==null&&!isNaN(E)&&E>0){base_url=base_url.replace(/&amp;/g,"&");if(((E-1)*per_page)>0){if(base_url.indexOf(C)>0&&base_url.indexOf("?")<0){document.location.href=base_url.replace(/.html/,"")+D+((E-1)*per_page)+C}else{if(base_url.indexOf(A)>0&&base_url.indexOf("?")<0){document.location.href=base_url.replace(/.htm/,"")+D+((E-1)*per_page)+A}else{if(base_url.indexOf(B)>0&&base_url.indexOf("?")<0){document.location.href=base_url.replace(new RegExp(/\/$/),"")+D+((E-1)*per_page)+B}else{document.location.href=base_url+"&start="+((E-1)*per_page)}}}}else{document.location.href=base_url}}}function marklist(id,name,state){var parent=document.getElementById(id);if(!parent){eval("parent = document."+id)}if(!parent){return }var rb=parent.getElementsByTagName("input");for(var r=0;r<rb.length;r++){if(rb[r].name.substr(0,name.length)==name){rb[r].checked=state}}}function viewableArea(B,A){if(!B){return }if(!A){B=B.parentNode}if(!B.vaHeight){B.vaHeight=B.offsetHeight;B.vaMaxHeight=B.style.maxHeight;B.style.height="auto";B.style.maxHeight="none";B.style.overflow="visible"}else{B.style.height=B.vaHeight+"px";B.style.overflow="auto";B.style.maxHeight=B.vaMaxHeight;B.vaHeight=false}}function dE(C,A){var B=document.getElementById(C);if(!A){A=(B.style.display==""||B.style.display=="block")?-1:1}B.style.display=(A==1)?"block":"none"}function subPanels(D){var B,C,A;if(typeof (D)=="string"){show_panel=D}for(B=0;B<panels.length;B++){C=document.getElementById(panels[B]);A=document.getElementById(panels[B]+"-tab");if(C){if(panels[B]==show_panel){C.style.display="block";if(A){A.className="activetab"}}else{C.style.display="none";if(A){A.className=""}}}}}function printPage(){if(is_ie){printPreview()}else{window.print()}}function displayBlocks(F,D,A){var C=(D.checked==true)?1:-1;if(A){C*=-1}var B=document.getElementsByTagName("DIV");for(var E=0;E<B.length;E++){if(B[E].className.indexOf(F)==0){B[E].style.display=(C==1)?"none":"block"}}}function selectCode(A){var D=A.parentNode.parentNode.getElementsByTagName("CODE")[0];if(window.getSelection){var B=window.getSelection();if(B.setBaseAndExtent){B.setBaseAndExtent(D,0,D,D.innerText.length-1)}else{var C=document.createRange();C.selectNodeContents(D);B.removeAllRanges();B.addRange(C)}}else{if(document.getSelection){var B=document.getSelection();var C=document.createRange();C.selectNodeContents(D);B.removeAllRanges();B.addRange(C)}else{if(document.selection){var C=document.body.createTextRange();C.moveToElementText(D);C.select()}}}}function play_qt_file(H){var E=H.GetRectangle();if(E){E=E.split(",");var C=parseInt(E[0]);var B=parseInt(E[2]);var G=parseInt(E[1]);var D=parseInt(E[3]);var F=(C<0)?(C*-1)+B:B-C;var A=(G<0)?(G*-1)+D:D-G}else{var F=200;var A=0}H.width=F;H.height=A+16;H.SetControllerVisible(true);H.Play()}function fontsizeup(){var A=getActiveStyleSheet();switch(A){case"A--":setActiveStyleSheet("A-");break;case"A-":setActiveStyleSheet("A");break;case"A":setActiveStyleSheet("A+");break;case"A+":setActiveStyleSheet("A++");break;case"A++":setActiveStyleSheet("A");break;default:setActiveStyleSheet("A");break}}function fontsizedown(){active=getActiveStyleSheet();switch(active){case"A++":setActiveStyleSheet("A+");break;case"A+":setActiveStyleSheet("A");break;case"A":setActiveStyleSheet("A-");break;case"A-":setActiveStyleSheet("A--");break;case"A--":break;default:setActiveStyleSheet("A--");break}}function setActiveStyleSheet(D){var C,B,A;for(C=0;(B=document.getElementsByTagName("link")[C]);C++){if(B.getAttribute("rel").indexOf("style")!=-1&&B.getAttribute("title")){B.disabled=true;if(B.getAttribute("title")==D){B.disabled=false}}}}function getActiveStyleSheet(){var B,A;for(B=0;(A=document.getElementsByTagName("link")[B]);B++){if(A.getAttribute("rel").indexOf("style")!=-1&&A.getAttribute("title")&&!A.disabled){return A.getAttribute("title")}}return null}function getPreferredStyleSheet(){return("A-")}function createCookie(C,D,E){if(E){var B=new Date();B.setTime(B.getTime()+(E*24*60*60*1000));var A="; expires="+B.toGMTString()}else{A=""}document.cookie=C+"="+D+A+"; path=/"}function readCookie(B){var D=B+"=";var A=document.cookie.split(";");for(var C=0;C<A.length;C++){var E=A[C];while(E.charAt(0)==" "){E=E.substring(1,E.length)}if(E.indexOf(D)==0){return E.substring(D.length,E.length)}}return null}function load_cookie(){var A=readCookie("style_cookie");var B=A?A:getPreferredStyleSheet();setActiveStyleSheet(B)}function unload_cookie(){var A=getActiveStyleSheet();createCookie("style_cookie",A,365)}onload_functions.push("load_cookie()");onunload_functions.push("unload_cookie()");function _hideBBCode(){this.objs=[];return this}_hideBBCode.prototype.IsDisplaySupported=function(){if(window.opera&&!document.childNodes){return false}if(document.getElementById||document.all){return true}return false};_hideBBCode.prototype.getObj=function(A){return(document.getElementById?document.getElementById(A):(document.all?document.all[A]:(document.layers?document.layers[A]:null)))};_hideBBCode.prototype.displayObj=function(D,B){var A=this.getObj(D);if(!A){return }var C=(document.layers?A:A.style);if(this.IsDisplaySupported()){C.display=B}else{C.visibility=(B=="none"?"hidden":"visible")}};_hideBBCode.prototype.open=function(D){var C="",A="hide"+Math.floor(Math.random()*15000);var B=(this.IsDisplaySupported()?"display:none;":"visibility:hidden;");if(document.layers){B="position:relative;"+B}C+='<div><a class="postlink" href="javascript:hideBBCode.showHide(\''+A+'\');" onmouseover="top.status=\'\';" onfocus="this.blur();">'+D+"</a></div>";C+='<div id="'+A+'" style="'+B+'">';document.write(C);this.objs[A]="none"};_hideBBCode.prototype.close=function(){document.write("</div>")};_hideBBCode.prototype.showHide=function(A){if(!this.objs[A]){return }this.objs[A]=((this.objs[A]=="none")?"block":"none");this.displayObj(A,this.objs[A])};var hideBBCode=new _hideBBCode();if((window.getSelection)||(document.getSelection)||(document.selection)){quoteselection=true}else{quoteselection=false}function quoteSelection(){if(!quoteselection){alert(L_BROWSER_NOT_SUPPORTED)}if(window.getSelection){text=window.getSelection()}else{if(document.getSelection){text=document.getSelection()}else{if(document.selection){text=document.selection.createRange().text}else{alert(L_BROWSER_ERROR);return }}}if((text)&&text!=""){quote="[quote]"+text+"[/quote]";message=document.forms[form_name].elements[text_name];if(message.value!=""){message.value=message.value+"\n"+quote+"\n"}else{message.value=quote+"\n"}message.focus();text="";return }else{alert(L_NO_TEXT_SELECTED)}}function showSmilies(A){window.open("./posting.php?sid=&mode=smilies&f="+A,"_phpbbsmilies","HEIGHT=350,resizable=yes,scrollbars=yes,WIDTH=300")}
