function getDatabasePath(){	     //var path = window.location.pathname.toLowerCase();  //convert to lowercase to match    //var nsfPos = path.indexOf(".nsf");     //return the path in correct case   //  return window.location.pathname.substr(0, nsfPos + 5);    // NC5th Aug 2009 - the above doesn't work anymore due to the new Substitution documents that are now in place	var http = document.getElementById("http_Value").value ; 	var ip = document.getElementById("InternetHost").value ;	var dbPath = document.getElementById("DbPath").value ; 	var url = http + "://" + ip + "/" + dbPath ;    	return url ; }//Shows the current tab as selected...function showTab( tab ){	document.getElementById(tab).className = "active" ; }// Opens the selected tab...function openNewDoc(  tabName , pageName) {	var pathVal  ; 	var path = getDatabasePath() ; 	if(pageName == "news"){ 		pathVal = path + "news?OpenForm" ;	} else if (pageName == "contactus" ) {		pathVal = path + "ReachRequest?OpenForm" ; 	} else {		pathVal = path + "lookup/" + pageName + "?OpenDocument"  ; 		}	window.location.href = pathVal + "&tab=" + tabName  ;}function submitSearch() {	var sQuery = document.getElementById("s2").value ; 	if( sQuery !== "") 	{		var tSearch = "SearchResults?SearchView&Query=" + sQuery ;	}else	{		var tSearch = "lookup/nosearchtext?OpenDocument" ;	}	var path = getDatabasePath() ; 	window.location.href = path + "/"  + tSearch ; 	return false ; }