// search funtion function doSearchETF ( s ) { var regExp1 = /\bfield\b/; var regExp2 = /<|>|\[|\]|\(|\)|\!/; var str = s.value; if ( regExp1.test( str ) || regExp2.test( str ) ) { alrt = "Please note that you can not include:"; alrt += "\n\nThe reserved word 'field'\nthe characters !, [, ], (, ), < or >"; alrt += "\n\nin your search query!\n\nIf you are confident that you know"; alrt += "\nwhat you are doing, then you can\nmanually produce the URL required."; s.focus(); return alert( alrt ); } if ( str == "" ) { alert("Please be sure to enter something to search for."); s.focus(); } else { document.location = "/" + document.forms[0].Path.value + "/index?open&type=Search&query=" + escape( str ) + "&SearchWV=TRUE&Include=article&start=1&count=100"; } } // write the pagedate out in long format function formatDate(numdate){ var numlist = numdate.split('/'); d=Number(numlist[0]); m=Number(numlist[1])-1; y=numlist[2]; var strmonth=new Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec") if (d == 0) { strdate = strmonth[m]+" "+y; } else { strdate = d+" "+strmonth[m]+" "+y; } return strdate; } // open a popup window function openWindowWH(url) { if (url.length > 0) { popupWin = open(url, "sideboxpopup", "resizable=no,scrollbars=yes,width=666,height=440"); } } // close popup window function closeWindow() { window.close() } // print the page function printWindow() { window.print() } function inStr(beginning, word1, word2) { check1 = new String(word2); returnInStr = word1.indexOf(word2, (beginning - 1)) + 1; return returnInStr; } function mid(inputMid, pos, l) { pos = pos - 1; if ((pos < inputMid.length) && ((pos + l) <= inputMid.length)) { returnMid = inputMid.substring(pos, pos + l); } else { returnMid = ""; } return returnMid; } function replaceSubstring (inputString, badString, goodString, caseSensitive) { fixedReplace = ""; UI = inputString; UB = badString; if ((caseSensitive != 1) && (caseSensitive != true)) { UI = inputString.toUpperCase(); UB = badString.toUpperCase(); } badEnd = -1; badLoc = UI.indexOf(UB); if (badLoc != -1) { for (x=1; (badLoc != -1); x++) { fixedReplace = fixedReplace + inputString.substring((badEnd + 1), badLoc) + goodString badEnd = badLoc + UB.length - 1; badLoc = UI.indexOf(UB, (badLoc + 1)); } fixedReplace = fixedReplace + inputString.substring((badEnd + 1), inputString.length); } else { fixedReplace = inputString; } return fixedReplace; } // similar to the StrLeft function function getFront(mainStr, searchStr ){ foundOffset = mainStr.indexOf(searchStr) if ( foundOffset == -1 ) { return null; } return mainStr.substring(0, foundOffset ); } // similar to the StrRight function function getEnd(mainStr, searchStr ){ foundOffset = mainStr.indexOf(searchStr) if ( foundOffset == -1 ) { return null; } return mainStr.substring( foundOffset + searchStr.length, mainStr.length); } function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i