//WARNING!!!!!//This page is part of the live site.   Any modifications to this page will have an immediate effect on the// database.  This page contains all formatting for the webpages.  Changing this one page will modify the look// of the entire site.// GaltNet code to rectify sloppy Browser detectionvar agt=navigator.userAgent.toLowerCase(); //alert( agt )// *** BROWSER VERSION *** // Note: On IE5, these return 4, so use is_ie5up to detect IE5. var is_major = parseInt(navigator.appVersion); var is_minor = parseFloat(navigator.appVersion);var jsFormName;// Note: Opera and WebTV spoof Navigator.  We do strict client detection. // If you want to allow spoofing, take out the tests for opera and webtv. var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)                 && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)                 && (agt.indexOf('webtv')==-1)); var is_nav2 = (is_nav && (is_major == 2)); var is_nav3 = (is_nav && (is_major == 3)); var is_nav4 = (is_nav && (is_major == 4)); var is_nav5 = (is_nav && (is_major == 5)); var is_nav5up = (is_nav && (is_major >= 5)); var is_webtv = (agt.indexOf('webtv') !=- 1); var is_ie   = (agt.indexOf("msie") != -1); var is_ie3  = (is_ie && (is_major < 4)); var is_ie4  = (is_ie && (is_major == 4) && (agt.indexOf("msie 4.0") !=-1) ); var is_ie5  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0") !=-1) );var is_ie501  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.01") !=-1) );  var is_ie55  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.5") !=-1) ); var is_ie6  = (is_ie && (is_major == 4) && (agt.indexOf("msie 6.0") !=-1) ); var is_ie7  = (is_ie && (is_major == 4) && (agt.indexOf("msie 7.0") !=-1) ); var is_ie4up  = (is_ie && !is_ie3 );var is_ie5up  = (is_ie && !is_ie3 && !is_ie4 );var is_ie6up  = (is_ie && !is_ie3 && !is_ie4 && !is_ie5 && !is_ie55);var is_ie7up  = (is_ie && !is_ie3 && !is_ie4 && !is_ie5 && !is_ie55 && !is_ie6);var is_ieMac  = (is_ie && (is_major == 4) && (agt.indexOf("mac") !=-1) ); var is_opera = (agt.indexOf("opera") != -1);var is_opera2 = (agt.indexOf("opera 2") != -1 || agt.indexOf("opera/2") != -1);var is_opera3 = (agt.indexOf("opera 3") != -1 || agt.indexOf("opera/3") != -1);var is_opera4 = (agt.indexOf("opera 4") != -1 || agt.indexOf("opera/4") != -1);var is_opera5 = (agt.indexOf("opera 5") != -1 || agt.indexOf("opera/5") != -1);var is_opera6 = (agt.indexOf("opera 6") != -1 || agt.indexOf("opera/6") != -1);var is_opera7 = (agt.indexOf("opera 7") != -1 || agt.indexOf("opera/7") != -1);var is_opera7up = (is_opera && !is_opera2 && !is_opera3 && !is_opera4 && !is_opera5 && !is_opera6);var is_konqueror = (agt.indexOf("konqueror") != -1);var is_konqueror1 = (agt.indexOf("konqueror/1") != -1);var is_konqueror2 = (agt.indexOf("konqueror/2") != -1);var is_konqueror3 = (agt.indexOf("konqueror/3") != -1);var is_konqueror3up = (is_konqueror && !is_konqueror1 && !is_konqueror2 );// may not need this var is_safari = (agt.indexOf("mozilla") != -1 && agt.indexOf("safari") != -1);if (is_safari == true) { is_nav5up = false ; }var is_lotusnotes = ( agt.indexOf("lotus") != -1)var is_Mac  = (agt.indexOf("mac")!=-1) ; var is_Windows  = (agt.indexOf("windows")!=-1) ;var is_linux = (agt.indexOf("inux")!=-1);var is_unix  = ((agt.indexOf("x11")!=-1) || is_linux);  editurl = "";//GaltNet BCM 12/13/2004 -- this is even easier, and works best for relative adressingvar AgreeToTerms = "" ;var useraccess = "" ;var tvusername = "" ;var tvmanageID = "" ;var pathView = document.URL;var GNServer = "" ;var GNURLPath = "" ;var GNServerName = "" ;var GNServerPath = "" ;var GNDBName = "" ;var ITMcookieName = "ITMX_AllCookie2";var defaultFrontPage = "";var GNPos ;var Doc1031Type = ""; var Rel1031DocKey = "";var Rel1031State = "";var Rel1031Action = "";var Pur1031DocKey = "";var Pur1031State = "";var Pur1031Action = "";if ( pathView.indexOf( "nsf" ) != -1 ) {	GNPos = pathView.indexOf("nsf");	GNURLPath= pathView.substring(0, GNPos+3);} else {	if ( pathView.indexOf( "servlet" ) != -1 ) {		GNPos = pathView.indexOf("servlet");		GNURLPath = pathView.substring(0, GNPos - 1) + "/tvsite.nsf";	} else {		GNURLPath= pathView ;	}}// Prevents names.nsf from breaking links on bad loginif ( GNURLPath.indexOf( "names.nsf" ) != -1 ) {	GNURLPath = replaceSubstring(GNURLPath, "names.nsf", "tvsite.nsf");}GNServer= GNURLPath;pos = GNURLPath.indexOf( "http://" )//alert ( GNURLPath ) ;if ( pos != -1 ) {	// normal http decode	GNServerName = GNServer.substring(7, GNServer.length) ;	pos2 = GNServerName.indexOf( "/" ) ;	if ( pos2 != -1 ) {		GNServerName = GNServerName.substring(0, pos2) ;		GNDBName = GNServer.substring(GNServerName.length + 8, GNServer.length) ;	} else {		GNDBName = "tvsite.nsf" ;	}	// alert (GNServerName) ;} else {	// https decode	GNServerName = GNServer.substring(8, GNServer.length) ;	pos2 = GNServerName.indexOf( "/" ) ;	if ( pos2 != -1 ) {		GNServerName = GNServerName.substring(0, pos2) ;		GNDBName = GNServer.substring(GNServerName.length + 9, GNServer.length) ;	} else {		GNDBName = "tvsite.nsf" ;	}	// alert (GNServerName) ;}// Server name has been found, now find the database name//alert ( GNDBName )GNServerPath = "http://" + GNServerName ;redirectedtomanage = 1;// Note, this is not a good browser detection method.// IE6 which is NOT DOM compliant, will be detected as such,// but DOM compliancy has a different event model (NS6, Firefox) & IE6 will failvar isDOM = (document.getElementById ? true : false); var isIE4 = ((document.all && !isDOM) ? true : false);var isNS4 = (document.layers ? true : false);check = GNURLPath + "/check.gif";uncheck= GNURLPath + "/uncheck.gif";thespacer = GNURLPath + "/Spacer3X3.gif";ucccheck = GNURLPath + "/ucccheck.gif";g_TransactionTypeSel = GNURLPath + "/ntoleftsidetransactionorange.gif";g_ThePropertySel = GNURLPath + "/ntoleftsidethepropertyorange.gif";g_ThePartiesSel = GNURLPath + "/ntoleftsidethepartiesorange.gif";g_OtherDetailsSel = GNURLPath + "/ntoleftsideotherdetailsorange.gif";g_SpecialInstructionsSel = GNURLPath + "/SpecialInstructionsOrange.gif";asteriskon = GNURLPath + "/asteriskon.gif";asteriskoff = GNURLPath + "/asteriskoff.gif";userbar_print_black = GNURLPath + "/userbar_print_black.gif" ;userbar_print_gray = GNURLPath + "/userbar_print_gray.gif" ;userbar_revise_black = GNURLPath + "/userbar_revise_black.gif" ;userbar_revise_gray = GNURLPath + "/userbar_revise_gray.gif" ;userbar_revise_gray = GNURLPath + "/userbar_revise_gray.gif" ;userbar_calculator_black = GNURLPath + "/userbar_calculator_black.gif" ;userbar_calculator_check_gray = GNURLPath + "/userbar_calculator_check_gray.gif" ;userbar_calculator_gray = GNURLPath + "/userbar_calculator_gray.gif" ;userbar_calendar_black = GNURLPath + "/userbar_calendar_black.gif" ;userbar_calendar_check_gray = GNURLPath + "/userbar_calendar_check_gray.gif" ;userbar_calendar_gray = GNURLPath + "/userbar_calendar_gray.gif" ;userbar_archive_gray = GNURLPath + "/userbar_archive_gray.gif" ;userbar_archive_black = GNURLPath + "/userbar_archive_black.gif" ;userbar_toucc_gray = GNURLPath + "/userbar_toucc_gray.gif" ;userbar_toucc_black = GNURLPath + "/userbar_toucc_black.gif" ;userbar_tocoop_gray = GNURLPath + "/userbar_tocoop_gray.gif" ;userbar_tocoop_black = GNURLPath + "/userbar_tocoop_black.gif" ;if (tvusername != "Anonymous" && useraccess == "-1") {	location.href( GNURLPath + "?logout&RedirectTo=" + GNURLPath + "/Sorry?OpenForm");}function ADMrefreshUserInfo() {	popURL = "User_LookupInfo?OpenForm&User='" + document.forms[0].$Authors.value + "'";	//alert(popURL)	ShowPopup( popURL, "1", "1");}function handler(e) {	if (is_nav5up || is_safari || is_konqueror3up ) {		var key = e.keyCode;	} else {		if (is_nav4)			var key = e.which;		else			var key = e.keyCode;	}	if (key == 13) {		//setLoginCookie('login');		signInUser(); //ELV20080624 tkt: 5618E571C2448		document.forms[1].submit();		return false;	} else		return true;}function handlers(e) {	if ( useraccess == "0" ) {		alert ( "Your account must be activated to use this feature") ;		return false;	}	if (isNS4) {		var key = e.which;	} else {		var key = e.keyCode;	}	if (key == 13) 	{		qstr = document.forms[0].Query_1.value;		if (qstr == "SEARCH" || qstr == "") {			alert("Please enter the search criteria.");		} else {//			hi= GNURLPath + "/vOrders_SearchResults?SearchView&SearchMax=20&SearchOrder=4&query=" + qstr;//			location.href = hi;			goSearch();		}		return false;	} else {		return true;	}}function replaceSubstring(charString, search, replace) {	var tempCharString = charString + '';	var searchChars = search + '';	var replaceChars = replace + '';	p = 0;	while (p < tempCharString.length && (p = tempCharString.indexOf(searchChars, p)) >= 0) {		tempCharString = tempCharString.substring(0, p) + replaceChars + tempCharString.substring(p + searchChars.length, tempCharString.length);		p += replaceChars.length;	}	return tempCharString;}function goBack() {	if ( useraccess == "1" || useraccess == "0" || jsIsNewDoc == "1" ) {		gotoFront();	} else {		if ( jsDocKey ) {			Link = "vOrdersByDocKeyMaskedAdmin/" + jsDocKey + "?OpenDocument";			siteURLLink( Link ) ;		} else if ( jsdocID ) {			Link = "vOrdersByUNIDMaskedAdmin/" + jsdocID + "?OpenDocument";			siteURLLink( Link ) ;		} else {			history.go(-1);		}	}}function gotoFront() {	formURL = GNURLPath + "/" + defaultFrontPage + "?OpenForm";	location.href = formURL ;}function switchView(viewname) {	val = viewname;	setCookie(val);	formURL = GNURLPath + "/" + defaultFrontPage + "?OpenForm" ;	location.href = formURL ;}function switchUserView(viewname) {	val = viewname;	setCookie(val);	formURL = GNURLPath + "/" + defaultFrontPage + "?OpenForm" ;	location.href = formURL ;}function switchAdminView(viewname) {	val = viewname;	location.href = GNURLPath + "/Admin_DisplayOrders?OpenForm&" + viewname + "&Start=1&Cat1=";}//ELV20091104 home.nsf: update cookie path to / so we can share it between home.nsf and tvsite.nsffunction setLoginCookie(name) {	f = document.forms[1];	var nextyear = new Date();	nextyear.setFullYear(nextyear.getFullYear() + 1);	username = f.Username.value;	password = escape(f.Password.value);	document.cookie = name + "=" + escape(username) + "; expires=" + nextyear.toGMTString()+ "; path=/";}function GetLoginCookie(cookiedata) {	f = document.forms[1];	username = unescape(cookiedata.slice( cookiedata.indexOf("=") + 1));		f.Username.value = username;}function retrieveCookieByName(Name) {	var search = Name + "="	if (document.cookie.length > 0) {		offset = document.cookie.indexOf(search);		if (offset != -1) {			offset += search.length ;			end = document.cookie.indexOf(";", offset) ;			if (end == -1) { end = document.cookie.length; }			GetLoginCookie(document.cookie.substring(offset, end));		} 	}}function show1031Pop(docType, relAction, relDocKey, relState, purAction, purDocKey, purState) {	Doc1031Type = docType;	Rel1031DocKey = relDocKey;	Rel1031State = relState;	Rel1031Action = relAction;	Rel1031Text = "";	Pur1031DocKey = purDocKey;	Pur1031State = purState;	Pur1031Action = purAction;	Pur1031Text = "";	TitleText = "";	if ( Rel1031Action == "A" ) {		Rel1031Text = "(Create New " + Doc1031Type + " Order)";	} else {		Rel1031Text = "(Edit Existing " +  Doc1031Type + " Order)";	}	if ( Pur1031Action == "A" ) {		Pur1031Text = "(Create New " + Doc1031Type + " Order)";	} else {		Pur1031Text = "(Edit Existing " +  Doc1031Type + " Order)";	}	if ( Doc1031Type == "Acris" ) {		TitleText = "Please select the property to which this Acris order applies";		if ( Rel1031State == "NY" && Pur1031State != "NY" ) {			if ( Rel1031Action == "A" ) {				urlString = "acrisetax?openform&1031Type=REL&1031DocKey=" + Rel1031DocKey;			} else if ( Rel1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Rel1031DocKey;			}			siteURLLink( urlString );			return;		} else if ( Rel1031State != "NY" && Pur1031State == "NY" ) {			if ( Rel1031Action == "A" ) {				urlString = "acrisetax?openform&1031Type=REP&1031DocKey=" + Rel1031DocKey;			} else if ( Rel1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Rel1031DocKey;			}			siteURLLink( urlString );			return;		} else if ( Rel1031State != "NY" && Pur1031State != "NY" ) {			return;		}		// at this stage, both states are NY, and so the chooser needs to show to choose the property		//else there is only one NY property and we will go straight to that one	} else {		TitleText = "Please select the property to which this Title order applies";	}	//put in logic to make the popup show over the actual order	hideDropDowns();	yPos = parseInt(jsMouseY) - 80;	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.getElementById("1031Pop").style.left = xPos + "px" ;		document.getElementById("1031Pop").style.top = yPos + "px" ;		document.getElementById("1031Pop").style.visibility = "visible" ;		document.getElementById("1031PopRelText").innerHTML = Rel1031Text ;		document.getElementById("1031PopPurText").innerHTML = Pur1031Text ;		document.getElementById("1031PopTitleText").innerHTML = TitleText ;	}	if ( is_ie4 ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.all["1031Pop"].style.left = xPos ;		document.all["1031Pop"].style.top = yPos ;				document.all["1031Pop"].style.visibility = "visible" ;		document.all["1031PopRelText"].innerHTML = Rel1031Text ;		document.all["1031PopPurText"].innerHTML = Pur1031Text ;		document.all["1031PopTitleText"].innerHTML = TitleText ;	}}function hide1031Pop() {	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("1031Pop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["1031Pop"].style.visibility = "hidden" ;	}	showDropDowns();}function create1031TitleAcris() {	urlString = "";	if (document.forms[0][ "1031PropertyChooser" ][ 0 ].checked == true) {		//Relinquished		if ( Doc1031Type == "Acris" ) {			if ( Rel1031Action == "A" ) {				urlString = "acrisetax?openform&1031Type=REL&1031DocKey=" + Rel1031DocKey;			} else if ( Rel1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Rel1031DocKey;			}		} else {			if ( Rel1031Action == "A" ) {				if ( Rel1031State == "NY" ) {					urlString = "TitleOrder?OpenForm&Type=REL&1031DocKey=" + Rel1031DocKey;				} else if ( Rel1031State == "FL" ) {					urlString = "TitleOrderFL?OpenForm&Type=REL&1031DocKey=" + Rel1031DocKey;				} else {					urlString = "TitleOrderOS?OpenForm&Type=REL&1031DocKey=" + Rel1031DocKey;				}			} else if ( Rel1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Rel1031DocKey;			}		}	} else {		//Replacement		var selectedProp = "";		for(i = 1; i < document.forms[0][ "1031PropertyChooser" ].length; i++) { // to select replacement prop 1,2 & 3			if(document.forms[0][ "1031PropertyChooser" ][i].checked)				selectedProp = document.forms[0][ "1031PropertyChooser" ][i].value;		}		if ( Doc1031Type == "Acris" ) {			if ( Pur1031Action == "A" ) {				urlString = "acrisetax?openform&1031Type="+selectedProp+"&1031DocKey=" + Rel1031DocKey;			} else if ( Pur1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Pur1031DocKey;			}		} else {			if ( Pur1031Action == "A" ) {				if ( Pur1031State == "NY" ) {					urlString = "TitleOrder?OpenForm&Type="+selectedProp+"&1031DocKey=" + Pur1031DocKey;				} else if ( Pur1031State == "FL" ) {					urlString = "TitleOrderFL?OpenForm&Type="+selectedProp+"&1031DocKey=" + Pur1031DocKey;				} else {					urlString = "TitleOrderOS?OpenForm&Type="+selectedProp+"&1031DocKey=" + Pur1031DocKey;				}			} else if ( Pur1031Action == "E" ) {				urlString = "vOrdersByDocKeyMaskedUser/" + Pur1031DocKey;			}		}	}	siteURLLink( urlString );}function showTitleOrderPop() {	hideDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.getElementById("titleorderPop").style.left = xPos + "px" ;		document.getElementById("titleorderPop").style.visibility = "visible" ;	}	if ( is_ie4 ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.all["titleorderPop"].style.left = xPos ;		document.all["titleorderPop"].style.visibility = "visible" ;	}}function hideTitleOrderPop() {	showDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("titleorderPop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["titleorderPop"].style.visibility = "hidden" ;	}}function showAcrisPop() {	hideDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		xPos = parseInt(document.body.clientWidth/2 - 261) ;		document.getElementById("acrisPop").style.left = xPos + "px" ;		document.getElementById("acrisPop").style.visibility = "visible" ;	}	if ( is_ie4 ) {		xPos = parseInt(document.body.clientWidth/2 - 261) ;		document.all["acrisPop"].style.left = xPos ;		document.all["acrisPop"].style.visibility = "visible" ;	}}function hideAcrisPop() {	showDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("acrisPop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["acrisPop"].style.visibility = "hidden" ;	}}function showUseraccessPop() {	hideDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.getElementById("useraccessPop").style.left = xPos + "px" ;		document.getElementById("useraccessPop").style.visibility = "visible" ;	}	if ( is_ie4 ) {		xPos = parseInt(document.body.clientWidth/2 - 123) ;		document.all["useraccessPop"].style.left = xPos ;		document.all["useraccessPop"].style.visibility = "visible" ;	}}function hideUseraccessPop() {	showDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("useraccessPop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["useraccessPop"].style.visibility = "hidden" ;	}}function showLegalFormsPop() {	hideDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		xPos = parseInt(document.body.clientWidth/2 - 261) ;		document.getElementById("legalFormsPop").style.left = xPos + "px" ;		document.getElementById("legalFormsPop").style.visibility = "visible" ;	}	if ( is_ie4 ) {		xPos = parseInt(document.body.clientWidth/2 - 261) ;		document.all["legalFormsPop"].style.left = xPos ;		document.all["legalFormsPop"].style.visibility = "visible" ;	}}function hideLegalFormsPop() {	showDropDowns();	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("legalFormsPop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["legalFormsPop"].style.visibility = "hidden" ;	}}function hideDropDowns() {	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		if ( document.getElementById("OrderType")  && is_ie ) {			document.getElementById("OrderType").style.visibility = "hidden" ;		}		if ( document.getElementById("StateCalc")  && is_ie ) {			document.getElementById("StateCalc").style.visibility = "hidden" ;		}		if ( document.getElementById("OrderType_2")  && is_ie ) {			document.getElementById("OrderType_2").style.visibility = "hidden" ;		}		if ( document.getElementById("Calculators")  && is_ie ) {			document.getElementById("Calculators").style.visibility = "hidden" ;		}				}	if ( is_ie4 ) {		if ( document.all["OrderType"] ) {			document.all["OrderType"].style.visibility = "hidden" ;		}		if ( document.all["StateCalc"] ) {			document.all["StateCalc"].style.visibility = "hidden" ;		}		if ( document.all["OrderType_2"] ) {			document.all["OrderType_2"].style.visibility = "hidden" ;		}		if ( document.all["Calculators"] ) {			document.all["Calculators"].style.visibility = "hidden" ;		}				}}function showDropDowns() {	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		if ( document.getElementById("OrderType")  && is_ie ) {			document.getElementById("OrderType").style.visibility = "visible" ;		}		if ( document.getElementById("StateCalc")  && is_ie ) {			document.getElementById("StateCalc").style.visibility = "visible" ;		}		if ( document.getElementById("OrderType_2")  && is_ie ) {			document.getElementById("OrderType_2").style.visibility = "visible" ;		}			}	if ( is_ie4 ) {		if ( document.all["OrderType"] ) {			document.all["OrderType"].style.visibility = "visible" ;		}		if ( document.all["StateCalc"] ) {			document.all["StateCalc"].style.visibility = "visible" ;		}		if ( document.all["OrderType_2"] ) {			document.all["OrderType_2"].style.visibility = "visible" ;		}	}}function gotoAcris() {	if ( jsAcrisUser == "Y" ) {		siteURLLink("AcrisETaxActSetup?OpenForm&AST=P");	} else {		siteURLLink("AcrisETaxActSetup?OpenForm&AST=T");	}}function GNsetFormCookie(value) {	formValue = value;	var GNnow = new Date();//	fixDate(GNnow);// 365 days in a year// 24 hours in a day// 60 minutes in an hour// 60 seconds in a minute// 1000 milliseconds in a second	 GNnow.setTime(GNnow.getTime() + 24 * 60 * 60 * 1000 * 365);// cookie expires in 365 days;  24hrs * 60 mins * 60 secs * 1000 * 365 ticks     GNsetCookie( tvusername + "_acrisPopup", formValue, GNnow, "/");     }function GNreadFormCookie() {	cookieValue = GNgetCookie( tvusername + "_acrisPopup");	return cookieValue ;}function GNgetCookie(name) {         var dc = document.cookie;         var prefix = name + "=";         var begin = dc.indexOf("; " + prefix);         if (begin == -1) {           begin = dc.indexOf(prefix);           if (begin != 0) return null;         } else           begin += 2;         var end = document.cookie.indexOf(";", begin);         if (end == -1)           end = dc.length;         return unescape(dc.substring(begin + prefix.length, end));       }//elv20091104: home.nsf: update cookie path to / to share it between home.nsf and tvsite.nsffunction GNsetCookie(name, value, expires, path, domain, secure) {	var curCookie = name + "=" + escape(value) +             ((expires) ? "; expires=" + expires.toGMTString() : "") +             "; path=/" +             ((domain) ? "; domain=" + domain : "") +             ((secure) ? "; secure" : "");	document.cookie = curCookie;	theurl = GNURLPath + "/AcrisETaxActSetup?OpenForm&AST=P";	location.href = theurl;	}//elv20091104: home.nsf: update cookie path to / to share it between home.nsf and tvsite.nsffunction setCookie(pValue) {	document.cookie = ITMcookieName + "="+pValue+"; path=/";}// ------------------- End of special code -------------------function movepic(img_name,img_src) {//alert( img_name + ",  " + img_src )	if ( document[img_name] ) {		document[img_name].src=img_src;	}}function w(theLine) {	document.write(theLine);}function ShowHideLayer( theobject, thevalue) {}function StripNumberFormatting(theobject) {		startvalue = theobject.value;		endvalue = "";	while (startvalue.search(",") != -1) {		startvalue = startvalue.replace(",","");	}	endvalue = startvalue;	if (isNaN(endvalue)) {		alert("Please enter a valid number123.");		endvalue = "";		theobject.focus();				//theobject.value = endvalue;		return false;		}		//else{			theobject.value = endvalue;//	  		return(true);//		}		}function ShowField(showobj) {	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) { 		if ( document.getElementById(showobj) ) {			document.getElementById(showobj).style.visibility = "visible"; 			document.getElementById(showobj).style.display = "";		} else {			//alert( showobj + " not found" );		}	} else if (is_ie4) {		if ( document.all["showobj"] ) {			document.all["showobj"].style.visibility = "visible";			document.all["showobj"].style.display = "";		} else {			//alert( showobj + " not found" );		}	} else if (is_nav4){		document.forms[0].RefreshFields.click();	}}function HideField(hideobj, fieldName) {	try{		document.forms[0].elements[fieldName].value = "";	}catch(e){}		if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) { 		if ( document.getElementById(hideobj ) ) {			document.getElementById(hideobj).style.visibility = "hidden"; 			document.getElementById(hideobj).style.display = "none";			document.getElementById(hideobj).value = "";		} else {			//alert( hideobj + " not found" );		}	} else if (is_ie4) {		if ( document.all[hideobj] ) {			document.all[hideobj].style.visibility = "hidden";			document.all[hideobj].style.display = "none";		} else {			//alert( hideobj + " not found" );		}	} else if (is_nav4){		document.forms[0].RefreshFields.click();	}}//Used to make fields "Readonly" in NS47function RemoveFocus(tmpObj) {	tmpObj.blur();}function go(number) {	if (useraccess == "0" || useraccess == "1"  || useraccess == "2" ) {		formnumber = 0;	} else {		formnumber = 1;	}	if ( useraccess == "-1" ) {		//alert ( "You must be logged in to use this feature") ;		showUseraccessPop();		return;	}	if (number == "1") {		ordertype = document.forms[formnumber].OrderType[document.forms[formnumber].OrderType.selectedIndex].value;		if (ordertype == "0") {			//Title insurance order was selected...			showTitleOrderPop();			return;		} else if (ordertype == "1") {			theurl = GNURLPath + "/CoopLienSearch?OpenForm";			location.href = theurl;					} else if (ordertype == "3") {			theurl = GNURLPath + "/OtherSearch?OpenForm";			location.href = theurl;					} else if (ordertype == "4") {			theurl = GNURLPath + "/1031Exchange?OpenForm";			location.href = theurl;		} else if (ordertype == "11") {			theurl = "/tvsite.nsf/coopDD?OpenForm";			location.href = theurl;		} else if (ordertype == "9") {			if ( useraccess == 2 ) {				theurl = GNURLPath + "/AcrisETaxActSetup?OpenForm&AST=P";				location.href = theurl;				} else {				dontShowPopup = GNreadFormCookie();				if ( dontShowPopup == "Y" ) {					theurl = GNURLPath + "/AcrisETaxActSetup?OpenForm&AST=P";					location.href = theurl;					} else {					showAcrisPop() ;					return;				}			}				} else if (ordertype == "2") {			//theurl = GNURLPath + "/UCCForm?OpenForm";			theurl = GNURLPath + "/UCCSelector?OpenForm";			location.href = theurl;					} else if (ordertype == "5") {			theurl = GNURLPath + "/CommLinesApplication?OpenForm";			location.href = theurl;					} else if (ordertype == "6") {			theurl = GNURLPath + "/PersonalLinesApplication?OpenForm";			location.href = theurl;					} else if (ordertype == "7") { //document recording			theurl = GNURLPath + (useraccess == "2" ? "/admindr2?OpenForm":"/public/TV_DocRecIntro?opendocument&Fr=TV") ;   			location.href = theurl;					} else if (ordertype == "8") {			location.href = GNURLPath + "/foreclosure?OpenForm";		} else if (ordertype == "12"){			window.open("/tvsite.nsf/gfe?openForm");		}		} else if (number == "2") {		if ( useraccess == "0" ) {			alert ( "Your account must be activated to use this feature") ;			return;		} else {			//theurl = GNURLPath + "/ClosingCalc?OpenForm";				theurl = GNURLPath + "/CCGFELanding?OpenForm";				xaction = document.forms[formnumber].StateCalc[document.forms[formnumber].StateCalc.selectedIndex].value;			if (xaction != "0") {				theurl = theurl + "&Type=" + xaction;			}			location.href = theurl;		}	} else if (number == "3") {		if ( useraccess == "0" ) {			alert ( "Your account must be activated to use this feature") ;			return;		} else {			ordertype = document.forms[formnumber].OrderType_2.selectedIndex ;			if (ordertype == "0") {				 if ( useraccess == "2" ) {					theurl = GNURLPath + "/AcrisETaxActSetup?OpenForm&AST=P";					location.href = theurl;					} else {					dontShowPopup = GNreadFormCookie();					if ( dontShowPopup == "Y" ) {						theurl = GNURLPath + "/AcrisETaxActSetup?OpenForm&AST=P";						location.href = theurl;						} else {						showAcrisPop() ;						return;					}				}			} else {				// put in logic to select the form				theurl = GNURLPath + "/LegalForms?OpenForm&F=" + ordertype ;			}			location.href = theurl;		}	} else if (number == "4") {		if ( useraccess == "0" ) {			alert ( "Your account must be activated to use this feature") ;			return;		} else {			theurl = GNURLPath + "/ClosingCalc?OpenForm";			theurl = theurl + "&Type=1";			location.href = theurl;		}	} else if (number == "5") {		theurl = GNURLPath + "/CommLinesApplication?OpenForm";		location.href = theurl;				} else if (number == "6") {			theurl = GNURLPath + "/PersonalLinesApplication?OpenForm";		location.href = theurl;						} else if (number == "7") {			theurl = GNURLPath + "/1031Exchange?OpenForm";		location.href = theurl;						}}function userGoTo( action ) {	jsAction = action ;	fullURL = GNURLPath + jsAction ;	location.href = fullURL ;}function siteURLLink( action ) {	jsAction = action ;	fullURL = GNURLPath + "/" +  jsAction ;	location.href = fullURL ;}function orderLink( author, action, link ) {	jsAuthor = author;	jsAction = action;	jsLink = link ;	//alert(jsAuthor)	//alert(tvusername)	if ( jsAuthor == tvaccessname ) {		fullURL = GNURLPath + "/" +  jsLink ;		location.href = fullURL ;	} else {		var warn_msg1 = "ALERT !!\n";		warn_msg1 += "__________________________________________\n\n";		warn_msg1 += "This order can only be edited by the original author.\n";		warn_msg1 += "If you need to have information in this order changed,\n";		warn_msg1 += "please contact the originator.\n\n";		warn_msg1 += "___________________________________________\n";		alert(warn_msg1);			return;	}}function ShowPopup(thescreen, width, height,showtop) {	//for the arg, include the ?OpenForm or ?OpenPage	if (isNaN(width))		width = "545";	if (isNaN(height))		height = "500";	if (isNaN(showtop))		showtop = 0;	var mypage = GNURLPath + "/" + thescreen;	winprops = 'height=' + height + ',width= ' + width + ',top=0,left=50,top=70,toolbar=' + showtop + ',location=0,directories=0,status=0,menubar=' + showtop + ',scrollbars=1,resizable';	win = window.open(mypage, "TitleVest", winprops);	if (parseInt(navigator.appVersion) >= 4) { 		win.window.focus();	 }}//elv20091123: home.nsf: replace Showpopup() function ShowPopup2( url ) {	win = window.open(url, "TitleVest", 'height= 500, width= 545, top=0, left=50, top=70, toolbar=0, location=0, directories=0, status=0, menubar=0, scrollbars=1, resizable');	if (parseInt(navigator.appVersion) >= 4) { 		win.window.focus();	 }}function FormatMoney(num, centsparam, dollarparam, commaparam) {	num = num.toString().replace(/\$|\,/g,'');	if(isNaN(num))		num = "0";	sign = (num == (num = Math.abs(num)));	num = Math.floor(num*100+0.50000000001);	cents = num%100;	num = Math.floor(num/100)	if (cents>=50 && centsparam != "cents")		num = num + 1;	num = num.toString();	if(cents<10)		cents = "0" + cents;	if (commaparam != "nocommas") {		for (var i = 0; i < Math.floor((num.length-(1+i))/3); i++)			num = num.substring(0,num.length-(4*i+3))+','+num.substring(num.length-(4*i+3));	}	if (cents>=50) {			}	if (dollarparam == "0" || dollarparam == "nodollar") {		dollarsign = ""	} else {		dollarsign = "$";	}	if (centsparam == "nocents") {		return (((sign)?'':'-') + dollarsign + num);		}	else if (centsparam == "cents") {		return (((sign)?'':'-') + dollarsign + num + '.' + cents);	} else  {		return (((sign)?'':'-') + dollarsign + num + ".00");	}}function FormatMoneyGN( fieldName, centsparam, dollarparam, commaparam) {	num= document.forms[0][ fieldName ].value ;	num = num.toString().replace(/\$|\,/g,'');	if(isNaN(num))		num = "0";	sign = (num == (num = Math.abs(num)));	num = Math.floor(num*100+0.50000000001);	cents = num%100;	num = Math.floor(num/100)	if (cents>=50 && centsparam != "cents")		num = num + 1;	num = num.toString();	if(cents<10)		cents = "0" + cents;	if (commaparam != "nocommas") {		for (var i = 0; i < Math.floor((num.length-(1+i))/3); i++)			num = num.substring(0,num.length-(4*i+3))+','+num.substring(num.length-(4*i+3));	}	if (cents>=50) {			}	if (dollarparam == "0" || dollarparam == "nodollar") {		dollarsign = ""	} else {		dollarsign = "$";	}		if (centsparam == "nocents") {		return (((sign)?'':'-') + dollarsign + num);		}	else if (centsparam == "cents") {		return (((sign)?'':'-') + dollarsign + num + '.' + cents);	} else  {		return (((sign)?'':'-') + dollarsign + num + ".00");	}		}function displayEditInfo( docStatus, docType, orderNumber, docKey, docAuthor, buyerAtty, sellerAtty, lenderAtty, otherAtty, numAttachments, viewedAttachment, propertyState, paramOne, paramTwo, paramThree, paramFour) {	if ( arguments[11] ) {	} else {		propertyState = "" ;	}	if ( arguments[12] ) {	} else {		paramOne = "" ;	}	if ( arguments[13] ) {	} else {		paramTwo = "" ;	}	if ( arguments[14] ) {	} else {		paramThree = "" ;	}	if ( arguments[15] ) {	} else {		paramFour = "" ;	}	jsOrderNumber = orderNumber;	docStatus = replaceSubstring( docStatus, " " , "" );	docType = replaceSubstring( docType, " " , "" );	docAuthor = docAuthor.toLowerCase();	buyerAtty = buyerAtty.toLowerCase();	sellerAtty = sellerAtty.toLowerCase();	lenderAtty = lenderAtty.toLowerCase();	otherAtty = otherAtty.toLowerCase();	canEditDoc = false;	if ( docAuthor.indexOf( LCcurrentuser ) != -1 ) {		canEditDoc = true;	}	//Write the "Order not yet placed" text for UCCs	if ( docType == "UCCORDER" ) {		 if (docStatus == "NEW" || docStatus == "DRAFT" || docStatus == "INCOMPLETE"  ) {//alert( docStatus )			idKey = "NYP" + docKey;			placedText = "(Order not yet Placed)";			if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {				document.getElementById( idKey ).innerHTML = placedText ;			} else {				document.all[ idKey ].innerHTML = placedText ;			}		 }	}	//Prepare for the attachments link	if ( numAttachments == "" || numAttachments == "0" ) {		w('<img src=\"spacer_trans.gif\" width=30 height=1>');	} else {		tLink = '<a href=\"' + GNURLPath + '/vORD_ViewAttachmentByDocKey/' + docKey + '?EditDocument\">';		tImage = '<img src=\"'  + GNURLPath + '/userbar_attach_' + viewedAttachment + '.gif\" width=11 height=21 title=\"This order has attachments that are ready for you to view/download.\" border="0">';		tFullLink = tLink + tImage + "</a>";		w( tFullLink );		numAttachmentsNum = numAttachments - 0;		if ( numAttachmentsNum < 6 ) {			w('<img src=\"' + GNURLPath + '/userbar_attach' + numAttachments + '_gray.gif\" width=9 height=21>');		}		w('<img src=\"' + GNURLPath + '/spacer_trans.gif\" width=10 height=1>');	}	//First, deal with the print order link	//alert("**" + docType + "**")	if ( docType == "UCCORDER" || docType == "ACRISETAX" || docType == "1031" ) {		w('<img src=\"spacer_trans.gif\" width=20 height=1>');	} else {		w('<a href=\"#\" onClick=\"ShowPopup(\'vOrders_PrintSummary/' + docKey + '?OpenDocument\',700,400, 1);return false;"><img title=\"View/Print Order Summary\" src=\"' + GNURLPath + '/userbar_print_black.gif\" width=20 height=21 border=\"0\"></a>');	}	//Next, deal with the edit link	if ( docType == "ACRISETAX" ) {		if ( canEditDoc == true ) {			w('<a href=\"#\" onclick=\"siteURLLink(\'vOrdersByDocKeyMaskedUser/' + docKey + '?EditDocument\');return false;\"><img src=\"' + GNURLPath + '/userbar_revise_black.gif\" title=\"Revise This Order...\"  width=20 height=21 border=\"0\"></a>');		} else {			w('<img src=\"spacer_trans.gif\" width=20 height=1>');		}	} else if (docStatus != "COMPLETED" && docStatus != "CLOSED" && docStatus != "CANCELLED"  ) {		if ( canEditDoc == true) {			w('<a href=\"#\" onclick=\"siteURLLink(\'vOrdersByDocKeyMaskedUser/' + docKey + '?EditDocument\');return false;\"><img src=\"' + GNURLPath + '/userbar_revise_black.gif\" title=\"Revise This Order...\"  width=20 height=21 border=\"0\"></a>');		} else {			w('<img src=\"spacer_trans.gif\" width=20 height=1>');		}	} else {		w('<img src=\"spacer_trans.gif\" width=20 height=1>');	}	// Now deal with the archive button	//if (docStatus == "COMPLETED" || docStatus == "CLOSED" || docStatus == "CANCELLED"  ) {	//	if ( docAuthor == LCcurrentuser ) {	//		w('<a href=\"#\" onClick=\"siteURLLink(\'Order_Archive?OpenForm&DocKey=' + docKey + '&Type=' + docStatus + '\');return false;\"><img src=\"userbar_archive_black.gif\" title=\"Archive This Order...\"  width=20 height=21 border=\"0\"></a>');	//	} else {	//		w('<img src=\"spacer_trans.gif\" width=20 height=1>');	//	}	//} else {	//	w('<img src=\"spacer_trans.gif\" width=20 height=1>');	//}	//Now deal with the delete button	if (docStatus == "DRAFT" || docStatus == "CANCELLED"  ) {		if ( docAuthor == LCcurrentuser ) {			w('<a href=\"#\" onClick=\"siteURLLink(\'Order_Delete?OpenForm&DocKey=' + docKey + '&Type=' + docType + '\');return false;\"><img src=\"' + GNURLPath + '/userbar_delete_black.gif\" title=\"Delete This Order...\"  width=20 height=21 border=\"0\"></a>');		} else {			w('<img src=\"spacer_trans.gif\" width=20 height=1>');		}	} else {		w('<img src=\"spacer_trans.gif\" width=20 height=1>');	}		//Now deal with Title Order Closing/Closing Costs/To Acris buttons	//For Title Orders	//ParamOne = Closing Scheduled date/time (or nothing)	//ParamTwo = Closing Invoice Generated  (YES = Closing Invoice generated)	//ParamThree = Closing Costs Calculated (Y/N/"")	//ParamFour = Acris Order Created ( orderNumber/NO)	if ( docType == "TITLEORDER" || docType == "TITLEORDEROS" || docType == "TITLEORDERFL") {		//Closing		if ( paramOne == "" ) {			imgHTML = "<img src=\""  + GNURLPath +  "/userbar_calendar_black.gif\" title= \"Click Here To Schedule A Closing\" width=20 height=21 border=\"0\">";		} else {			percentPos = paramOne.indexOf( "%1%");			closingDate = paramOne.substring(0, percentPos);			closingTime = paramOne.substring(percentPos+3, paramOne.length);			imgHTML = "<img src=\""  + GNURLPath +  "/userbar_calendar_check_black.gif\" title= \"Closing Scheduled For " + closingDate + " at " + closingTime + ".  Click here to see or modify the details of this closing.\" width=20 height=21 border=\"0\">";		}		w('<a href=\"#\"  onClick=\"siteURLLink(\'vAdminTitleOrderToClosingByDocKey/' + docKey + '?EditDocument\');return false;\">' + imgHTML + '</a>');		//Closing Invoice		if ( paramTwo == "" ) {		} else {			percentPos = paramOne.indexOf( "%1%");			closingDate = paramOne.substring(0, percentPos);			closingTime = paramOne.substring(percentPos+3, paramOne.length);			imgHTML = "<img src=\"" + GNURLPath + "/userbar_invoice_gray.gif\"  width=20 height=21 border=\"0\">";			w('<a href=\"#\" onClick=\"ShowPopup(\'vORD_ClosingInvoiceByDocKey/' + docKey + '?EditDocument\', 700, 550, 1);return false;\">' + imgHTML + '</a>');		}		//Now deal with the closing costs		if ( propertyState == "NY" || propertyState == "FL" ) {			if ( paramThree == "" ) {			} else if ( paramThree == "N" ) {				imgHTML = "<img src=\"" + GNURLPath + "/userbar_calculator_black.gif\" title=\"Click here to generate closing costs for this order\" width=20 height=21 border=\"0\">";				w('<a href=\"#\" onClick=\"siteURLLink(\'vAdminTitleOrderToCCByDocKey/' + docKey + '?EditDocument\');return false;\">' + imgHTML + '</a>');			} else if ( paramThree == "Y" ) {				imgHTML = "<img src=\"" + GNURLPath + "/userbar_calculator_check_black.gif\" title= \"Closing costs have been generated.  Click here to see or modify the closing costs.\" width=20 height=21 border=\"0\">";				w('<a href=\"#\" onClick=\"siteURLLink(\'vAdminTitleOrderToCCByDocKey/' + docKey + '?EditDocument\');return false;\">' + imgHTML + '</a>');			}		}		//Now deal with the to acris button		if ( propertyState == "NY"  ) {//alert( paramFour )			if ( paramFour == "NO" ) {				if ( jsOrderNumber != "" && jsOrderNumber != "(not assigned)" ) {					imgHTML = "<img src=\"" + GNURLPath + "/userbar_toacris_black.gif\" title= \"Click here to create an Acris E-Tax order based on this order\" width=55 height=21 border=\"0\">";					w('<a href=\"#\" onClick=\"siteURLLink(\'acrisetax?OpenForm&ORDNUM=' + jsOrderNumber + '\');return false;\">' + imgHTML + '</a>');				}			} else {				imgHTML = "<img src=\"" + GNURLPath + "/userbar_toacris_black_check.gif\" title= \"Click here to edit the Acris E-Tax order  that was based on this order\" width=55 height=21 border=\"0\">";				w('<a href=\"#\" onClick=\"siteURLLink(\'vOrdersByDocKeyMaskedUser/' + paramFour + '?EditDocument\');return false;\">' + imgHTML + '</a>');			}		}	}	//Now deal with the alert to the attorney	idKey = "ATT" + docKey;	attorneyText = "";	if ( LCcurrentuser == buyerAtty ) {		attorneyText = "(you are the Buyer's Attorney)";	} else if (  LCcurrentuser == sellerAtty ) {		attorneyText = "(you are the Seller's Attorney)";	} else if (  LCcurrentuser == lenderAtty ) {		attorneyText = "(you are the Lender's Attorney)";	} else if (  LCcurrentuser == otherAtty ) {		attorneyText = "";	}	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById( idKey ).innerHTML = attorneyText ;	} else {		document.all[ idKey ].innerHTML = attorneyText ;	}	}function DisplayViewGraphicAdmin(FormStatus, unacceptable, modified, expired, AcrisRecordedStatus) {	FormStatus = FormStatus.toUpperCase();	//Determine which graphic we should show...	if (expired == "1")		graphicname = "markedforarchive";	else if (unacceptable == "1" && modified == "1")		graphicname = "icon_order_both";	else if (unacceptable == "1")		graphicname = "icon_order_un";	else if (modified == "1")		graphicname = "icon_order_edit";	else if (FormStatus == "PLACED")			graphicname = "icon_order_new";	else if (AcrisRecordedStatus == "recorded")		graphicname = "icon_filing_complete";	else if (FormStatus == "COMPLETED" || FormStatus == "CLOSED")		graphicname = "icon_order_complete";	else if (FormStatus == "CANCELLED")		graphicname = "icon_order_cancelled";	else		graphicname = "icon_order";	w('<img src=\"' + GNURLPath + '/' + graphicname + '.gif\" border="0">');}function DisplayViewGraphicUser(FormStatus, unacceptable, modified, expired, AcrisRecordedStatus) {	FormStatus = FormStatus.toUpperCase();	//Determine which graphic we should show...			//alert("here: " + AcrisRecordedStatus);	if (expired == "1") {		graphicname = "markedforarchive";		titleval = "This order has been marked for archiving.";	} else if (unacceptable == "1" && modified == "1") {		graphicname = "document";		titleval = "TitleVest personnel have been made aware of the changes you've made to this order, and will be reviewing it shortly.";	} else if (unacceptable == "1") {		graphicname = "icon_document_attention";		titleval = "This order requires your attention.  Please click on the 'revise' graphic, make necessary modifications, and save your changes.";	} else if (FormStatus == "DRAFT") {		graphicname = "incomplete";		titleval = "This order is a draft.  You will need to complete this order by clicking on the revise graphic before this order can be submitted to TitleVest.";	} else if (modified == "1") {		graphicname = "document";		titleval = "TitleVest personnel have been made aware of the changes you've made to this order, and will be reviewing it shortly.";	} else if (FormStatus == "PLACED")	{		graphicname = "document";		titleval = "This order has been placed, and is awaiting review and confirmation from TitleVest personnel.";	} else if (AcrisRecordedStatus == "recorded") {		graphicname = "icon_filing_complete";		titleval = "According to the NYC ACRIS Website, your E-tax forms have been filed.";	} else if (FormStatus == "COMPLETED" || FormStatus == "CLOSED") {		graphicname = "icon_order_complete";		titleval = "This order is complete and results should be available by clicking on the paperclip graphic.";	} else if (FormStatus == "CANCELLED") {		graphicname = "icon_order_un";		titleval = "This order has been cancelled.";	} else if (FormStatus == "INCOMPLETE") {		graphicname = "incomplete";		titleval = "This order is incomplete.  You will need to complete this order by clicking on the revise graphic before this order can be submitted to TitleVest.";	} else if (FormStatus == "ACTIVE") {		titleval = "This order has been reviewed by TitleVest, and is being processed.  This graphic will change to a checkmark when this order is complete, and results will be posted here.";		graphicname = "document";	} else {		graphicname = "icon_order";		titleval = "";	}	w('<img src=\"' + GNURLPath + '/' + graphicname + '.gif\" title=\"' + titleval + '\" border=0>');}function drawNewHeader(frontpage, nh_useraccess, nh_livehelpWrite) {	if ( arguments[2] ) {	} else {		nh_livehelpWrite = "yes" ;	}	jsUserAccess = nh_useraccess	if ( jsUserAccess == "2" ) {		defaultFrontPage = "Fronta";	} else if ( jsUserAccess == "1" || jsUserAccess == "0" ) {		defaultFrontPage = "Frontc";	} else {		defaultFrontPage = "Front";	}//alert(jsUserAccess)			w('<table border="0" cellspacing="0" cellpadding="0" width="760">');	//w('<colgroup>');	//w('<col width="71"><col width="22"><col width="58"><col width="23"><col width="78"><col width="23"><col width="72"><col width="32"><col width="94"><col width="62"><col width="225">');	//w('</colgroup>');		//w('<tr><td colspan="11" height=30 bgcolor="#FFFFFF">&nbsp;</td></tr>');	//w('<tr><td colspan="11" height=20 align="center" bgcolor="#FFFFFF"><font size=2 color="#FF0000"><b>TitleVest.com will be down for Maintenance on Friday, July 21 from 3pm until 7pm.</b></font></td></tr>');	//w('<tr><td colspan="11" height=8 bgcolor="#FFFFFF">&nbsp;</td></tr>');		if(getFormName().toUpperCase() != "USER_REGISTER_1031") {	    w('<tr><td bgcolor="#FFFFFF">');	    drawHeader_InPage(frontpage, nh_useraccess, nh_livehelpWrite);	    w('</td></tr>');	    /*		    w('<tr><td colspan="11" height=8 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/spacer_trans.gif" width=1 height=8 border="0"></td></tr>');		w('<tr bgcolor="#09357A">');		w('<td width=71 height=33><a href="' + GNURLPath + '/' + defaultFrontPage + '?OpenForm"><img src="' + GNURLPath + '/top_new_home.gif" width=71 height=22 border="0"></a></td>');		w('<td width=22><img src="' + GNURLPath + '/spacer_trans.gif" width=22 height=1></td>');		w('<td width=58><a href="'+ GNURLPath + '/FAQ?OpenForm"><img src="' + GNURLPath + '/top_new_faq.gif" width=58 height=22 border="0"></a></td>');		w('<td width=23><img src="' + GNURLPath + '/spacer_trans.gif" width=23 height=1></td>');		w('<td width=78><a href="' + GNURLPath + '/aboutus?OpenForm"><img src="' + GNURLPath + '/top_about_us.gif" width=78 height=22 border="0"></a></td>');		w('<td width=23><img src="' + GNURLPath + '/spacer_trans.gif" width=23 height=1></td>');		w('<td width=72><a href="' + GNURLPath + '/careers?OpenForm"><img src="' + GNURLPath + '/top_careers.gif" width=72 height=22 border="0"></a></td>');		w('<td width=32><img src="' + GNURLPath + '/spacer_trans.gif" width=32 height=1></td>');		w('<td width=94><a href="' + GNURLPath + '/contactus?OpenForm"><img src="' + GNURLPath + '/top_contact.gif" width=94 height=22 border="0"></a></td>');		w('<td width=62 valign="top" align="left"><img src="' + GNURLPath + '/top_angle.gif" width=62 height=33 border="0"></td>');		w('<td width=225 bgcolor="#FFFFFF">');		if ( jsUserAccess == "2"  || jsUserAccess == "deny" ) {			w('&nbsp;</td></tr>');			} else {			if ( nh_livehelpWrite == "yes" ) {				w("<a href='http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&byhref=1&imageUrl=http://www.titlevest.com/images' target='chat25870545'  onClick=\"javascript:window.open('http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&imageUrl=http://www.titlevest.com/images&referrer='+escape(document.location),'chat25870545','width=472,height=320');return false;\" ><img src='http://server.iad.liveperson.net/hc/25870545/?cmd=repstate&site=25870545&&ver=1&imageUrl=http://www.titlevest.com/images' name='hcIcon' width=191 height=33 border=0></a>");			} else {			}			w('</td></tr>');							//<!-- END LivePerson Button code -->		}			w('<tr><td colspan=11 bgcolor="#09357A" height=12><img src="' + GNURLPath + '/spacer_trans.gif" width="1" height="12" border="0"></td></tr>');		w('<tr><td colspan=11 bgcolor="#FFFFFF" height=6><img src="' + GNURLPath + '/spacer_trans.gif" width="1" height="6" border="0"></td></tr>');		*/	}			if ( jsUserAccess != "deny") {		var bb5613333553= getCookie2('_bb5613333553'); //elv20080625 tkt: 5618E571C2448		if ( jsUserAccess == "-1") {			if ( bb5613333553 ){ //elv20080625 tkt: 5618E571C2448				location =  "/tokenlinks.nsf/bb5613333553?OpenForm&id="+bb5613333553;				return;			}						//Login screen for anonymous users			//<!-- START LOGO & LOGIN -->			//w('<tr><td colspan=11 bgcolor="#FFFFFF">');			w('<tr><td  bgcolor="#FFFFFF">');			w('<table width="750" border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" align="center">');			w('<colgroup><col width="431"><col width="319"></colgroup>');			w('<tr><td width=431 height=70><img src="' + GNURLPath + '/top_tv_logo.gif" width=431 height=55 border="0"></td>');			w('<td width=319 align="right" valign="top">');			w('<table width=319 border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" align="center" style="border: 1px #C6C6C6 solid;">');			w('<colgroup><col width="111"><col width="208"></colgroup>');			w('<tr bgcolor="#AFCDE9"><td width=111 height=21><img src="' + GNURLPath + '/top_login.gif" width=111 height=21 border="0"></td>');			w('<td width= 208><a href="' + GNURLPath + '/User_Register?OpenForm"><img src="' + GNURLPath + '/top_notmember.gif" width=205 height=21 border="0"></a></td></tr>');			w('<tr><td colspan=2>');			w('</FORM>');			w('<FORM NAME="_CustomLoginForm" METHOD=post ACTION="' + GNURLPath + '?login">');			w('<table width="319" border="0" cellpadding="0" cellspacing="0">');			w('<tr><td height=20 valign="bottom" class="login_prompt">&nbsp;&nbsp;&nbsp;USERNAME:</td>');			w('<td colspan=2 valign="bottom" class="login_prompt">PASSWORD:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="' + GNURLPath + '/User_ForgotPassword?OpenForm" class="link_login_grey">Forgot Your Login?</a></td></tr>');			w('<tr><td width=133 height=25>&nbsp;&nbsp;<input type="text" name="Username" class="INPTxt" size="17" value="">');			retrieveCookieByName( 'login' );			w('</td>');			w('<td width=133><input id="nsPswd" name="Password" value="" type=password size="17" onKeydown="return handler(event);"></td>');			w('<td width=53><a onClick="setLoginCookie(\'login\');document.forms[1].submit();return false;" href="javascript:void(0);"><img src="' + GNURLPath + '/go_red.gif" width=37 height=12 border="0"></a></td></tr>');			w('</table>');				w('</td></tr>');			w('</table>');			w('</td></tr>');			w('</table>');				w('</td></tr>');			//w('<tr><td colspan="11" height=6 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/spacer_trans.gif" width="1" height="6" border="0"></td></tr>');			w('<tr><td height=6 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/spacer_trans.gif" width="1" height="6" border="0"></td></tr>');		} else {			// Smaller header space for those already logged in			//w('<tr><td colspan="11" bgcolor="#FFFFFF">');			w('<tr><td bgcolor="#FFFFFF">');			w('<table width="760" border=0 cellspacing=0 cellpadding=0>');			w('<colgroup><col width="350"><col width="410"></colgroup>');			//var strcookie = GNgetCookie("ITMX_AllCookie2");			//var strFName = getFormName();			//if(jsFormName == "1031Exchange" || document.forms[0].name == "_Admin_1031" || jsFormName == "1031ByStatus" || strcookie=="vOrders_1031" || strFName == "vADMIN1031Orders") {			//			w('<tr><td width="350" rowspan="2" height=42><img src="' + GNURLPath + '/1031vest.gif" valign="top"><img src="' + GNURLPath + '/powered.gif" valign="top"></td>');			//}			//else{			//			w('<tr><td width="350" rowspan="2" height=42><img src="' + GNURLPath + '/TV_logo_interior_small.gif" width=301 height=36 valign="top"></td>');			//}			var strLogo = getLogo();			w('<tr><td width="350" rowspan="2" height=42>' + strLogo + '</td>');			w('<td width=410 height=20 valign="top"><font color="#555555">Welcome, ' + tvusername + '.</font></td></tr>');			w('<tr><td height=21>');			w('<table width="410" border=0 cellspacing=0 cellpadding=0>');			w('<colgroup><col width="130"><col width="40"><col width="55"><col width="55"><col width="130"></colgroup>');			if ( jsUserAccess == "2") {				AgreeToTerms = "Agree"; 				w('<tr><td width=130 height=21>&nbsp;</td><td width=40></td>');			} else if ( jsUserAccess == "1") {				editurl = GNURLPath + '/vUSRAllByDocKeyUser/' + tvmanageID + '?EditDocument';				if (AgreeToTerms == "") {					// location.href = editurl;					redirectedtomanage = 0;				}				w('<tr><td class="login_prompt" width=130 height=21 valign="top">MANAGE MY ACCOUNT</td><td width=40 valign="top"><a href="' + editurl + '"><img src="' + GNURLPath + '/arrow_red.gif" width=12 height=10 border=0></a></td>');			} else if ( jsUserAccess == "0") {//alert("useraccess 0 logic")				w('<tr><td width=130 height=2>&nbsp;</td><td width=40>&nbsp;</td>');			}			if ( !bb5613333553 ){ //elv20080625 tkt: 5618E571C2448				w('<td class="login_prompt" width=55 valign="top">LOGOUT</td><td width=55 valign="top"><a href="' + GNURLPath + '/?logout&RedirectTo=' + GNURLPath + '/redirector2" ALT=""><img src="' + GNURLPath + '/arrow_red.gif" width=12 height=10 border="0"></a></td>');				w('<td valign="top" width=130><a class="link_login_grey" href="' + GNURLPath + '/?logout&RedirectTo=' + GNURLPath + '/redirector2" ALT="">If you are not this user, CLICK HERE</a></td>');			}else{				w('<td class="login_prompt" width=55 valign="top">LOGOUT</td><td width=55 valign="top"><a href="' + GNURLPath + '/signout?readform&RedirectTo=' + GNURLPath + '/redirector2" ALT=""><img src="' + GNURLPath + '/arrow_red.gif" width=12 height=10 border="0"></a></td>');				w('<td valign="top" width=130><a class="link_login_grey" href="' + GNURLPath + '/signout?readform&RedirectTo=' + GNURLPath + '/redirector2" ALT="">If you are not this user, CLICK HERE</a></td>');			}									w('</td></tr></table>');			w('</td></tr></table>');			w('</td></tr>');			//w('<tr><td colspan="11" height=6 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/spacer_trans.gif" width=1 height=6 border=0></td></tr>');			w('<tr><td height=6 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/spacer_trans.gif" width=1 height=6 border=0></td></tr>');		}	} else {		if ( jsUserAccess == "2") { AgreeToTerms = "Agree"; }		if (AgreeToTerms == "" ) {			redirectedtomanage = 0;		}		var srtUrlArg = getURLArg("Fr");		var strFName = getFormName();		if(getFormName().toUpperCase() == "USER_REGISTER_1031" || srtUrlArg == "1031" || strFName == "1031Exchange") {			//w('<tr><td width="350" rowspan="2" height=42><img src="' + GNURLPath + '/1031vest.gif" valign="top"><img src="' + GNURLPath + '/powered.gif" valign="top"></td>');			//w('<tr><td colspan="11" width="70%" height=42 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/1031vest.gif" valign="top"><img src="' + GNURLPath + '/powered.gif" valign="top"></td></tr>');					w('<tr><td  width="70%" height=42 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/1031vest.gif" valign="top"><img src="' + GNURLPath + '/powered.gif" valign="top"></td></tr>');				} else {			//w('<tr><td colspan="11" height=42 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/TV_logo_interior_small.gif" width=301 height=36 valign="top"></td></tr>');					w('<tr><td  height=42 bgcolor="#FFFFFF"><img src="' + GNURLPath + '/TV_logo_interior_small.gif" width=301 height=36 valign="top"></td></tr>');				}		}	//END THE LOGIN SCREEN	w('</table>');	if (frontpage != "yes") {		w('<tr><td width=5></td><td width=750 height=3 bgcolor="#C6C6C6"><img src="' + GNURLPath + '/spacer_trans.gif" width=1 height=1 border=0></td><td width=5></td></tr>');	}}function drawNewFooter(barColor,nh_livehelpWrite) {	if ( arguments[0] ) {	} else {		barColor = "grey" ;	}	if ( arguments[1] ) {	} else {		nh_livehelpWrite = "yes" ;	}	var currYear = new Date();	var sId = getSiteId();		w("<table width='760px' border='0' cellpadding='0' cellspacing='0' bgcolor='#FFFFFF' align='center'>");	w("<tr><td ><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='5' border='0'></td></tr>");	w("<tr>");	//w("<td width='5px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	//w("<td width='746px' align=center><img src='" + GNURLPath + "/images/footer_line.gif' border='0' width='746'></td>");	w("<td width='746px' height='28' class='footerLine'>&nbsp;</td>");	//w("<td width='5px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("</tr>");	w("<tr><td  height='44' align='center'>");	w("<a href='"+ getPageURL(sId,'HOME') +"' class='footerNav'>HOME</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'ADV') +"' class='footerNav'>THE ADVANTAGE</a>&nbsp;");	/* elv20091117: tkt:12F58F97EEEE26*/	w("<a href='"+ getPageURL(sId,'NEWS') +"' class='footerNav'>IN THE NEWS</a>&nbsp;");		w("<a href='"+ getPageURL(sId,'FAQ') +"' class='footerNav'>FAQ's</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'ABOUT') +"' class='footerNav'>ABOUT US</a>&nbsp;");	//w("<a href='"+ getPageURL(sId,'CAREER') +"' class='footerNav'>CAREERS</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'CONTACT') +"' class='footerNav'>CONTACT US</a>&nbsp;");	w(getJSLinkTextForFooter(sId,"TERMS","TERMS OF AGREEMENT") +"&nbsp;");	w(getJSLinkTextForFooter(sId,"PRIVACY","PRIVACY STATEMENT") +"&nbsp;");//	w("<a href='"+ getPageURL(sId,'PRIVACY') +"' class='footerNav'>PRIVACY STATEMENT</a>");	w("</td></tr>");	w("<tr><td align='center' class='grey11'>&copy; " + currYear.getFullYear() + " TITLEVEST &bull; 1031VEST &bull; INSUREVEST. ALL RIGHTS RESERVED</td></tr>");	w("<tr><td ><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='20' border='0'></td></tr>");	w("</table>");}function getFormName() {	var strLocation = location.href;	strLocation = (strLocation.split('?'))[0].split('/');	var strform = strLocation[strLocation.length-1];	return strform;}function getURLArg(arg) {	var y = "";	var s=location.href.toUpperCase();	if(s.indexOf(arg.toUpperCase())==-1) return "";	var x=s.split(arg.toUpperCase()+"=");	if(x.length > 1) {		 y=x[1].split('&');		 return y[0];	} else {	 	return y;	}			}function drawNewHeader_Home(frontpage, nh_useraccess, nh_livehelpWrite) {	if ( arguments[2] ) {	} else {		nh_livehelpWrite = "yes" ;	}	jsUserAccess = nh_useraccess;	if ( jsUserAccess == "2" ) {		defaultFrontPage = "Fronta";	} else if ( jsUserAccess == "1" || jsUserAccess == "0" ) {		defaultFrontPage = "Frontc";	} else {		defaultFrontPage = "Front";	}		var liveHelpImg = "http://server.iad.liveperson.net/hc/25870545/?cmd=repstate&site=25870545&&ver=1&imageUrl=http://www.titlevest.com/images/livehelp";	var liveHelpURL = "http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&byhref=1&imageUrl=http://www.titlevest.com/images/livehelp";		var sId = getSiteId();		w("<table width='997px' border='0' cellpadding='0' cellspacing='0' bgcolor='#FFFFFF' align='center'>");	w("<tr><td colspan='6'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='20' border='0'></td></tr>");	w("<tr><td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("<td >");	w("<table width='518px' border='0' cellpadding='0' cellspacing='0'>");	w("<tr>");	w("<td style='width:45px;'><div class='elButton_1'><a href='"+ getPageURL(sId,'HOME') +"'></a></div></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("<td style='width:132px;'><div class='elButton_2'><a href='"+ getPageURL(sId,'ADV') +"'></a></div></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	/* elv20091117: tkt:12F58F97EEEE26*/	//w("<td style='width:132px;'><div class='elButton_7'><a href='"+ getPageURL(sId,'CLE') +"'></a></div></td>");	w("<td style='width:98px;'><div class='elButton_7'><a href='"+ getPageURL(sId,'NEWS') +"'></a></div></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");		w("<td style='width:44px;'><div class='elButton_3'><a href='"+ getPageURL(sId,'FAQ') +"'></a></div></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("<td style='width:76px;'><div class='elButton_4'><a href='"+ getPageURL(sId,'ABOUT') +"'></a></div></td>");	//w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	//w("<td style='width:69px;'><div class='elButton_5'><a href='"+ getPageURL(sId,'CAREER') +"'></a></div></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("<td style='width:92px;'><div class='elButton_6'><a href='"+ getPageURL(sId,'CONTACT') +"'></a></div></td>");	w("</tr>");	w("</table>");	w("</td>  	");	w("<td width='168px'><img src='" + GNURLPath + "/images/spacer.gif' width='168' height='1' border='0'></td>   ");		w("<td width='98px'>");	if ( jsUserAccess == "2"  || jsUserAccess == "deny" ) {		w('&nbsp;</td>');		} else {		if ( nh_livehelpWrite == "yes" ) {			w("<a href='" + liveHelpURL + "' target='chat25870545'  onClick=\"javascript:window.open('"+liveHelpURL+"&referrer='+escape(document.location),'chat25870545','width=472,height=320');return false;\" ><img src='" + liveHelpImg + "' border='0'</a>");		} else {			w("&nbsp;");		}		w('</td>');							//<!-- END LivePerson Button code -->	}		//w("<td width='98px'><a href='" + liveHelpURL + "' target='chat25870545'  onClick=\"javascript:window.open('"+liveHelpURL+"&referrer='+escape(document.location),'chat25870545','width=472,height=320');return false;\" ><img src='" + liveHelpImg + "' border='0'</a></td>");//	w("<td width='98px'><a href='#'><img src='images/live_help.gif' border='0'></a></td>");	w("<td width='6px'><img src='" + GNURLPath + "/images/spacer.gif' width='6' height='1' border='0'></td>");	w("<td width='137px'><a href='" +  "/home.nsf/refFrnd' target='_blank'><img src='" + GNURLPath + "/images/refer.gif' border='0'></a></td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("</tr>");	w("<tr>");	w("<td colspan='6'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='20' border='0'></td>");	w("</tr>");	w("</table>");}var regRedir = "";function drawLoginHome(nh_useraccess, notusetoken) {	jsUserAccess = nh_useraccess;	if ( jsUserAccess != "deny") {		var bb5613333553= getCookie2('_bb5613333553');		if ( jsUserAccess == "-1") {			if ( !notusetoken && bb5613333553 ){ //elv20080625 tkt: 5618E571C2448				//location =  "/tokenlinks.nsf/bb5613333553?OpenForm&id="+bb5613333553+"&u="+location;				location =  "/tokenlinks.nsf/bb5613333553?OpenForm&id="+bb5613333553+"&u=";				return;			}else{				//elv20080904: tkt:46E4F693D5234 if notusetoken is true means the token previously failed so we destroy the				//cookie to not call it anymore.				resetLoginCookie('_bb5613333553');			}						w('</FORM>');			w('<FORM NAME="_CustomLoginForm" METHOD=post ACTION="' + GNURLPath + '?login">');			w('<input type="hidden" name="RedirectTo" value="">');	//ELV20080624 tkt: 5618E571C2448				w("<tr>");			w("<td colspan='3' class='grey11'>Username:</td>");			w("<td width='222' rowspan='6' valign='top' align='right'><a href='" + GNURLPath + "/User_Register?OpenForm"+(regRedir ? "&regRedir="+regRedir : "")+"'><img src='" + GNURLPath + "/images/not_member_back.gif' valign='right' border='0'></a></td>");			w("</tr>");			w("<tr>");			w("<td colspan='3' ><input type='text' class='inputBox' size='25' name='Username'></td>");			w("</tr>");			w("<tr> ");			w("<td colspan='3'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='3' border='0'></td>");			w("</tr>");			w("<tr>");			w("<td colspan='3' class='grey11' valign='bottom'>Password:</td>");			w("</tr>");			w("<tr>");			w("<td width='163'><input id='nsPswd' type='password' class='inputBox' size='25' name='Password' onKeydown='return handler(event);'></td>");			//w("<td width='100' align='left'><a onClick=setLoginCookie('login');document.forms[1].submit();return false; href='javascript:void(0);'><input type='image' src='" + GNURLPath + "/images/login.gif'></a></td>");			w("<td width='100' align='left'><a onClick='signInUser();document.forms[1].submit()' href='javascript:void(0);'><input type='image' src='" + GNURLPath + "/images/login.gif'></a></td>"); //ELV20080624 tkt: 5618E571C2448			w("<td width='24'>&nbsp;</td>");			w("</tr>");			w("<tr>");			w("<td colspan='3' height='25'><a href='" + GNURLPath + "/User_ForgotPassword?OpenForm' class='pass'>Forgot your login?</a></td>");			w("</tr>");			w("<tr><td colspan='3' class='grey11'>");			w("<input type='checkbox' name='action' value='1'>Save my password"); //ELV20080624 tkt: 5618E571C2448			w("</td></tr>");						retrieveCookieByName( 'login' );			//w("<tr> ");			//w("<td colspan='3'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='8' border='0'></td>");			//w("</tr>");			w("<tr>");   			w("<td colspan='4'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='10' border='0'></td>");			w("</tr>");				} else {				w("<tr>");			w("<td colspan='4' valign='bottom' height='1' class=\"loginborder\"><img src='" + GNURLPath + "/images/spacer.gif' width='479' height='1' border='0'></td>");			w("</tr>");			w("<tr>");			w("<td colspan='4'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='10' border='0'></td>");			w("</tr> ");			w("<tr>");			w("<td colspan='4' height='40' class='welcome'>&nbsp;Welcome, " + tvusername + "</td>");			w("</tr>  ");			w("<tr>");			if ( !bb5613333553 ){ //elv20080625 tkt: 5618E571C2448				w("<td width='224' height='35'>&nbsp;<a href='" + GNURLPath + "/?logout&RedirectTo=" + GNURLPath + "/redirector2' class='pass'>If you are not this user, click here.</a></td>");			}else{				w("<td width='224' height='35'>&nbsp;<a href='" + GNURLPath + "/signout?ReadForm&RedirectTo=" + GNURLPath + "/redirector2' class='pass'>If you are not this user, click here.</a></td>");			}			if ( jsUserAccess == "2") {				AgreeToTerms = "Agree"; 				w("<td width='155'>&nbsp;</td>");			} else if ( jsUserAccess == "1") {				editurl = GNURLPath + '/vUSRAllByDocKeyUser/' + tvmanageID + '?EditDocument';				if (AgreeToTerms == "") 					redirectedtomanage = 0;				w("<td width='155'><a href='" + editurl + "'><img src='" + GNURLPath + "/images/manage_my.gif' border='0'></a></td>");			} else if ( jsUserAccess == "0") {				w("<td width='155'>&nbsp;</td>");			}						w("<td width='25'><img src='" + GNURLPath + "/images/spacer.gif' width='5' height='1' border='0'></td>");			if ( !bb5613333553 ){ //elv20080625 tkt: 5618E571C2448				w("<td width='75'><a href='" + GNURLPath + "/?logout&RedirectTo=" + GNURLPath + "/redirector2'><img src='" + GNURLPath + "/images/logout.gif' border=0></a></td>");			}else{				w("<td width='75'><a href='" + GNURLPath + "/signout?ReadForm&RedirectTo=" + GNURLPath + "/redirector2'><img src='" + GNURLPath + "/images/logout.gif' border=0></a></td>");			}			w("</tr>");			w("<tr>");			w("<td colspan='4'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='10' border='0'></td>");			w("</tr>");			w("<tr>");			w("<td colspan='4' valign='bottom' height='1' class=\"loginborder\"><img src='" + GNURLPath + "/images/spacer.gif' width='479' height='1' border='0'></td>");			w("</tr>");			w("<tr>");   			w("<td colspan='4'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='21' border='0'></td>");			w("</tr>");		}	}}function drawNewFooter_Home() {	var currYear = new Date();	var sId = getSiteId();	w("<table width='997px' border='0' cellpadding='0' cellspacing='0' bgcolor='#FFFFFF' align='center'>");	w("<tr><td colspan='3'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='5' border='0'></td></tr>");	w("<tr>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("<td width='977px' height='28' class='footerLine'>&nbsp;</td>");	w("<td width='10px'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='1' border='0'></td>");	w("</tr>");	w("<tr><td colspan='3' height='44' align='center'>");	w("<a href='"+ getPageURL(sId,'HOME') +"' class='footerNav'>HOME</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'ADV') +"' class='footerNav'>THE ADVANTAGE</a>&nbsp;");	//elv20091117: tkt: 12F58F97EEEE26		w("<a href='"+ getPageURL(sId,'NEWS') +"' class='footerNav'>IN THE NEWS</a>&nbsp;");			w("<a href='"+ getPageURL(sId,'CLE') +"' class='footerNav'>CLE</a>&nbsp;");			w("<a href='"+ getPageURL(sId,'FAQ') +"' class='footerNav'>FAQ's</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'ABOUT') +"' class='footerNav'>ABOUT US</a>&nbsp;");	//w("<a href='"+ getPageURL(sId,'CAREER') +"' class='footerNav'>CAREERS</a>&nbsp;");	w("<a href='"+ getPageURL(sId,'CONTACT') +"' class='footerNav'>CONTACT US</a>&nbsp;");	w(getJSLinkTextForFooter(sId,"TERMS","TERMS OF AGREEMENT") +"&nbsp;");	w(getJSLinkTextForFooter(sId,"PRIVACY","PRIVACY STATEMENT") +"&nbsp;");//	w("<a href='"+ getPageURL(sId,'PRIVACY') +"' class='footerNav'>PRIVACY STATEMENT</a>");	w("</td></tr>");	w("<tr><td colspan='3' align='center' class='grey11'>&copy; " + currYear.getFullYear() + " TITLEVEST &bull; 1031VEST &bull; INSUREVEST. ALL RIGHTS RESERVED</td></tr>");	w("<tr><td colspan='3'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='20' border='0'></td></tr>");	w("</table>");}function drawHeader_InPage(frontpage, nh_useraccess, nh_livehelpWrite) {	if ( arguments[2] ) {	} else {		nh_livehelpWrite = "yes" ;	}	jsUserAccess = nh_useraccess;	if ( jsUserAccess == "2" ) {		defaultFrontPage = "Fronta";	} else if ( jsUserAccess == "1" || jsUserAccess == "0" ) {		defaultFrontPage = "Frontc";	} else {		defaultFrontPage = "Front";	}	var liveHelpImg = "http://server.iad.liveperson.net/hc/25870545/?cmd=repstate&site=25870545&&ver=1&imageUrl=http://www.titlevest.com/images/livehelp";	var liveHelpURL = "http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&byhref=1&imageUrl=http://www.titlevest.com/images/livehelp";		var sId = getSiteId();		w("<table width='740px' border='0' cellpadding='0' cellspacing='0' bgcolor='#FFFFFF' align='center'>");	w("<tr><td colspan='6'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='8' border='0'></td></tr>");	w("<tr><td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	w("<td align=left>");	w("<table width='480px' border='0' cellpadding='0' cellspacing='0'>");	w("<tr>");	w("<td style='width:45px;'><div class='elButton_1'><a href='"+ getPageURL(sId,'HOME') +"'></a></div></td>");	w("<td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	w("<td style='width:110px;'><div class='elButton_2'><a href='"+ getPageURL(sId,'ADV') +"'></a></div></td>");	//elv20091118: tkt: 12F58F97EEEE26		w("<td style='width:98px;'><div class='elButton_7'><a href='"+ getPageURL(sId,'NEWS') +"'></a></div></td>");		w("<td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	w("<td style='width:40px;'><div class='elButton_3'><a href='"+ getPageURL(sId,'FAQ') +"'></a></div></td>");	w("<td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	w("<td style='width:76px;'><div class='elButton_4'><a href='"+ getPageURL(sId,'ABOUT') +"'></a></div></td>");	//w("<td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	//w("<td style='width:60px;'><div class='elButton_5'><a href='"+ getPageURL(sId,'CAREER') +"'></a></div></td>");	w("<td width='1px'><img src='" + GNURLPath + "/images/spacer.gif' width='1' height='1' border='0'></td>");	w("<td style='width:80px;'><div class='elButton_6'><a href='"+ getPageURL(sId,'CONTACT') +"'></a></div></td>");	w("</tr>");	w("</table>");	w("</td> ");	w("<td width='28px'><img src='" + GNURLPath + "/images/spacer.gif' width='28' height='1' border='0'></td>   ");	w("<td width='98px'>");	if ( jsUserAccess == "2"  || jsUserAccess == "deny" ) {			w('&nbsp;</td>');		} else {		if ( nh_livehelpWrite == "yes" ) {			//w("<a href='http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&byhref=1&imageUrl=http://www.titlevest.com/images' target='chat25870545'  onClick=\"javascript:window.open('http://server.iad.liveperson.net/hc/25870545/?cmd=file&file=visitorWantsToChat&site=25870545&imageUrl=http://www.titlevest.com/images&referrer='+escape(document.location),'chat25870545','width=472,height=320');return false;\" ><img src='" + GNURLPath + "/images/live_help.gif' border='0'</a>");			w("<a href='" + liveHelpURL + "' target='chat25870545'  onClick=\"javascript:window.open('"+liveHelpURL+"&referrer='+escape(document.location),'chat25870545','width=472,height=320');return false;\" ><img src='" + liveHelpImg + "' border='0'</a>");		}		w('</td>');	}	w("<td width='3px'><img src='" + GNURLPath + "/images/spacer.gif' width='3' height='1' border='0'></td>");	w("<td width='137px'><a href='" + GNURLPath + "/fReferFriend' target='_blank'><img src='" + GNURLPath + "/images/refer.gif' border='0'></a></td>");	w("<td width='5px'><img src='" + GNURLPath + "/images/spacer.gif' width='5' height='1' border='0'></td>");	w("</tr>");	w("<tr>");	w("<td colspan='6'><img src='" + GNURLPath + "/images/spacer.gif' width='10' height='20' border='0'></td>");	w("</tr>");	w("</table>");	}function getLogo() {			var strcookie = GNgetCookie("ITMX_AllCookie2");			var strFName = getFormName();			var strLogo = "";			if(jsFormName == "1031Exchange" || document.forms[0].name == "_Admin_1031" || jsFormName == "1031ByStatus" || (strcookie=="vOrders_1031" && strFName.toUpperCase() == "FRONTC") || strFName == "vADMIN1031Orders") {						strLogo = '<img src="' + GNURLPath + '/1031vest.gif" valign="top"><img src="' + GNURLPath + '/powered.gif" valign="top">';			} else {						strLogo = '<img src="' + GNURLPath + '/TV_logo_interior_small.gif" width=301 height=36 valign="top"></td>';			}			return strLogo;}//ELV20091104: home.nsf: update cookie path to / to share it between tvsite.nsf and home.nsffunction setNewCookie(name, value, expires, path, domain, secure) {	var curCookie = name + "=" + escape(value) +      ((expires) ? "; expires=" + expires.toGMTString() : "") +      "; path=/" +      ((domain) ? "; domain=" + domain : "") +      ((secure) ? "; secure" : "");	document.cookie = curCookie + ";";}function setSiteCookie(id) {	setNewCookie("siteid",id,null,null,"");}function getSiteId() {	var s = getURLArg("Fr");	s = s.split("#")[0];	//If site id is not available from url then get it from cookie	if (s == null || s =="") 		s = retrieveCookie("siteid");	if (s == null || s =="") 		return "TV"	else		return s;}function retrieveCookie(Name) {	var search = Name + "="	var cookieValue = "";	if (document.cookie.length > 0) {		offset = document.cookie.indexOf(search);		if (offset != -1) {			offset += search.length ;			end = document.cookie.indexOf(";", offset) ;			if (end == -1) { end = document.cookie.length; }			cookiedata = document.cookie.substring(offset, end);			cookieValue = unescape(cookiedata.slice( cookiedata.indexOf("=") + 1));			} 	}	return cookieValue;}//elv20091123: home.nsf: updated to point to home.nsffunction getPageURL(sId,pId) { sId = (sId == ""?"TV":sId); if (pId == "HOME") 	return "/home.nsf/redirector2?openform&Fr=" + sId; if (pId == "TERMS" ) { 		return "/home.nsf/popup_Terms_" + sId + "?OpenPage&Fr=" + sId; } if (pId == "PRIVACY" ) { 		return "/home.nsf/popup_Privacy_"+ sId+"?OpenPage&Fr=" + sId; }  if (pId == "CLE" ){	return GNURLPath +"/cle"; } //elv20091117: tkt:12F58F97EEEE26 if (pId == "NEWS" ){	return "/home.nsf/News_Summary?OpenForm"; }  if(sId != "" && pId != "")	 return  "/home.nsf/public/"+sId + "_" + pId + "?opendocument&Fr="+sId;else	return "/home.nsf/front?openform&Fr=" + sId;	}//elv20091123: home.nsf: ShowPopup2 replaced ShowPopupfunction getJSLinkTextForFooter(sId,pId,txt) {		return '<a class="footerNav" href="javascript:void(0);" onclick="ShowPopup2(\''+ getPageURL(sId,pId) + '\');return false;">' + txt + '</a>';}//ELV20070828 Display Vest Insurance promotion question in TitleOrder & Coop Lien Search wizards//ELV20100125: tkt: 20D53039C75C57 Deprecated/* function showVIPop() {  var qRequest = document.forms[0].quoteRequest.value; if (!qRequest){ //this is true when user did not select yes or no in popup	 toggleDropDowns("TransactionType;PropertyCounty;PropertyState;OPPaidBy_Value;Survey;Backtitle", "hidden");	 if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		 xPos = parseInt(document.body.clientWidth/2 - 261) ;		 document.getElementById("viPop").style.left = xPos + "px" ;		 document.getElementById("viPop").style.visibility = "visible" ;	 }	 if ( is_ie4 ) {		 xPos = parseInt(document.body.clientWidth/2 - 261) ;		 document.all["viPop"].style.left = xPos ;		 document.all["viPop"].style.visibility = "visible" ;	 } }else{ 	Place_Save_Order(); }} *///ELV20070828 Hide Vest Insurance promotion question in TitleOrder & Coop Lien Search wizards//ELV20100125: tkt: 20D53039C75C57 Deprecated/* function hideVIPop() {	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.getElementById("viPop").style.visibility = "hidden" ;	}	if ( is_ie4 ) {		document.all["viPop"].style.visibility = "hidden" ;	}	toggleDropDowns("TransactionType;PropertyCounty;PropertyState;OPPaidBy_Value;Survey;Backtitle", "visible");	Place_Save_Order();} *///ELV20070828 Set Vest Insurance promotion question in TitleOrder & Coop Lien Search wizardsfunction setQuoteRequest(value){	if (is_ie5up || is_nav5up || is_safari || is_konqueror3up || is_opera7up ) {		document.forms[0].quoteRequest.value = value;	 }	if ( is_ie4 ) {		document.forms[0].quoteRequest.value = value;	 }	hideVIPop(); }//ELV20070829: Hide/Show drop down objects.//the dropDowns param is a string of drop down names delimited by semi-colons.//action has only two values "hidden" and "visible"function toggleDropDowns(dropDowns, action) {	var oDropDown, arrDropDowns;	if ( is_ie ) {		arrDropDowns = dropDowns.split(";");		for(var i=0; i<arrDropDowns.length; i++){			if ( is_ie4 ) {				oDropDown = document.all[arrDropDowns[i]];			 }else{		 		oDropDown = document.getElementById(arrDropDowns[i]);			 } 				if ( oDropDown ){				try{					oDropDown.style.visibility = action;				}catch(e){}			}		 		}					}}//elv20080228: prevents form submittion when user hits enterfunction noSubmitOnEnter( e ) {	var code = 0;	if (!e) var e = window.event;	if (e.keyCode) code = e.keyCode;	else if (e.which) code = e.which; return (code == 13) ?  false : true; }//ELV20080624 tkt: 5618E571C2448//elv20091104: home.nsf insert tvsite.nsf to redirect request from home.nsffunction signInUser(){ var form = document.forms[1]; if ( form.action.checked ){	 	form.RedirectTo.value = "/tvsite.nsf/bb5613333553?ReadForm&a=1"; } setLoginCookie('login'); }//elv20080624 tkt: 5618E571C2448function getCookie2(name) {	var offset = document.cookie.indexOf(name);	var res = '';	if (offset != -1) {			offset += name.length+1 ;			end = document.cookie.indexOf(";", offset) ;			if (end == -1) { end = document.cookie.length; }			res = document.cookie.substring(offset, end);	} 	return res;	}//elv20080624 tkt: 5618E571C2448//elv20091104: home.nsf update path to / to share it between home.nsf and tvsite.nsffunction resetLoginCookie(name) {	document.cookie = name + "=; expires=Tue, 01-Jan-1980 00:00:00 GMT; path=/";}//elv20080624 tkt: 5618E571C2448function confirmAutoLogin(){ var form = document.forms[1]; if ( form.action.checked ){	if ( !confirm("Please make sure you select this option from a secure computer\n( one that is not shared ) since may have security implications.\nDo you want to continue?") ){		form.action.checked = false;		} }}//elv20081202 tkt: 189A4EDA0DD950function trim2( s ) {	return s.replace(/^\s+|\s+$/g,"");}//elv20091201: FrontcDetailfunction switchViewDetail(viewname) {	val = viewname;	setCookie(val);		formURL = GNURLPath + "/FrontcDetail?OpenForm" ;	location.href = formURL ;}