function MM_reloadPage(init) { //reloads the window if Nav4 resized if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) { document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }} else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload(); } function doSearch ( s ) { var regExp1 = /\bfield\b/; var regExp2 = /[(,),<,>,\[,\]]/; var str = s.value; if ( str == "" ){ alert("Please enter something to search for"); s.focus(); } else { openDbRelativeURL("search?SearchView&Query=" + escape( str ) + "&SearchWV=TRUE&SearchFuzzy=TRUE&count=20&start=1"); } } function openDbRelativeURL( url, target ){ target = (target == null ) ? window : target; if(location.pathname.match('.nsf')) path = location.pathname.split('.nsf')[0] + '.nsf/'; else path = 'http://www.privacy.vic.gov.au/privacy/web.nsf/'; target.location.href = path + url; } function returnFalse(s){ //guess the field if not supplied s = (s == null) ? document.forms[0].Query : s; doSearch(s); return false; } function openImage(loc,w,h) { path = location.pathname.split('.nsf')[0] + '.nsf/'; window.open(path + loc,"","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width="+w+",height="+h); } function linkalert(URL){ var newline = '\n'; var sMessage = "You are about to leave the Privacy Victoria website."; sMessage = sMessage + newline + newline; sMessage = sMessage + "If this is your intention please click: " sMessage = sMessage + newline; sMessage = sMessage + "- OK to proceed or" sMessage = sMessage + newline; sMessage = sMessage + "- CANCEL to return to the current page"; if (confirm(sMessage)) { window.location = URL; return false; } }