var timeInterval=10;function doAjaxRequest(c,d,b){var a="row"+c;if(document.getElementById(a)!=null&&(document.getElementById(a).className)=="collapseMinus"){document.getElementById(a).className="expandPlus";document.getElementById(c).className="hide"}else{if((document.getElementById(a).className=="expandPlus")||(document.getElementById(a).className=="spacerExpandPlus expandPlus")){if(document.getElementById(c).innerHTML==""){loadData("browseClasses.do?classType="+d+"&className="+c+"&fieldCount="+escape(b),c,null)}document.getElementById(a).className="collapseMinus"}document.getElementById(c).className="show"}}var targetId;function initRequest(a){if(window.XMLHttpRequest){req=new XMLHttpRequest()}else{if(window.ActiveXObject){isIE=true;req=new ActiveXObject("Microsoft.XMLHTTP")}}}function loadData(b,a,c){if(b.split("?")[0]!=""){b=b+"&dummy="+new Date().getTime()}else{b=b+"?dummy="+new Date().getTime()}targetId=a;initRequest(b);req.onreadystatechange=function(){processRequest(a)};req.open("GET",b,true);req.send(c)}function processRequest(a){if(req.readyState==4){if(req.status==200){document.getElementById(a).innerHTML="";var b=req.responseText;document.getElementById(a).innerHTML=b}}else{document.getElementById(a).innerHTML=""+_gl_getMessage("SHIST_LBL_LODG")+""}}function alterText(c,f){var g=(document.all)?1:0;var d=0;if(parseInt(navigator.appVersion)>=5){d=1}if(d){var e=document.getElementById(c);e.innerHTML=f}else{if(g){var a=document.all[c];if(a.firstChild){a.removeChild(a.firstChild)}var b=document.createElement("div"+Math.random());b.innerHTML=f;a.appendChild(b)}}}function returnIPCValue(f){var b=document.getElementsByName("classItem"+f);var g="(";var e=b.length;var d=0;for(d=0;d-1||d.value.length>0){d.value=d.value.replace(";","");d.value+=" OR "}insertAtCursor(d,c)}}else{childWin=window.open(a,"Corporate Tree","dependent=yes,resizable=yes,width=1000px,height=680px,resizable=yes,scrollbars=yes'")}}function openResourceIpcWindow(a){openLoadingIcon();setTimeout(function(){openResourceIpcWindowMethod(a)},timeInterval)}function openResourceIpcWindowMethod(f){if(f=="Any IPC"||f=="Current IPC-Advanced"||f=="Current IPC-Core"||f=="Current IPC-Core Additional"||f=="Current IPC-Advanced Inventive"||f=="Current IPC-Advanced Additional"||f=="Current IPC-Core Inventive"){classType="ipc8"}else{if(f=="US Class Main"||f=="Current US Class-Main"||f=="US Class Original"){classType="uspc"}else{if(f=="Derwent Manual Code"){if("true"==document.getElementById("isCpiSubscribed").value){classType="manual"}else{classType="manual-epi"}}else{if(f="Derwent Class Main"){classType="dwpi"}}}}var b="browseClasses.do?classType="+escape(classType)+"&className=";if(document.all){var e=window.showModalDialog(b,self,"dialogWidth=950px;dialogHeight=670px;center:yes;status:off;resizable:no;scroll bars:no;help:no");if(e){var a=e.split(",");var d=a[0];var c=a[1];insertString(d,document.getElementById("tagsTextArea"),c)}}else{childWin=window.open(b,"IPCBrowsing","dependent=yes,resizable=no,width=1000px,height=630px,resizable=no,scroll bars=no'")}}var globalCursorPos;function setCursorPos(){globalCursorPos=getCursorPos(document.getElementById("tagsTextArea"))}function getCursorPos(b){var h=b.value;var a=0;if(document.getSelection){a=b.selectionStart;position2=b.selectionEnd}else{if(document.selection&&document.selection.createRange){var g=document.selection.createRange();var f=g.text;var c="#%~";g.text=f+c;g.moveStart("character",(0-f.length-c.length));var d=b.value;g.text=f;for(i=0;i<=d.length;i++){var e=d.substring(i,i+c.length);if(e==c){a=(i-f.length);position2=(a+f.length)}}}}return a}function moveCorporateCodeToParent(f){var c="";var d=document.getElementsByName("ChosenFld");if(d!=null&&d.length>0){for(var e=0;e-1){var b=g.id.split("_")[0];if(document.getElementById(b).checked==false){if(c.length>0){c+=' OR "'+g.value+'"'}else{c='"'+g.value+'"'}}}else{if(g.checked==true){if(c.length>0){c+=' OR "'+g.value+'"'}else{c='"'+g.value+'"'}}}}}if(document.all){window.returnValue=c;self.close()}else{if(f!=-1){window.opener.document.getElementById("txt"+f).value=c;window.opener.document.getElementById("txtarea"+f).value=c;if(window.opener.document.getElementById("hiddenText"+f)){window.opener.document.getElementById("hiddenText"+f).value=0}window.opener.document.getElementById("tempTextAreaContent"+f).value="cmp=("+c+")";window.opener.populateQueryPreViewer()}else{if(window.opener.document.getElementById("tagsTextArea")!=undefined){c=" ("+c+") ";c="cmp="+c;var a=window.opener.document.getElementById("tagsTextArea");if(a.value.indexOf(";")>-1||a.value.length>0){a.value=a.value.replace(";","");a.value+=" OR "}insertAtCursor(window.opener.document.getElementById("tagsTextArea"),c)}}window.close()}}function changeUpperCase(){var a=document.getElementById("query").value;document.getElementById("query").value=a.toUpperCase()}function checkEnter(a){var b;if(document.all){b=window.event.keyCode}else{b=a.which}if(b==13){return false}else{return true}}function handleKeyEvent(b){var a=b.keyCode||b.which;if(a==13){getClassResults("classSearchResult");if(!document.all){b.preventDefault()}return false}}function selectChildItems(c){var b=0;var d=new Array;var a;if(document.getElementById("row"+c).className=="collapseMinus"){if(document.getElementById(c).className=="show"){d=document.getElementById(c).getElementsByTagName("table");for(b=0;b