	var isAJAXCompliant = false;
	if (window.XMLHttpRequest) {
		var Ricola_ContentRequest = new XMLHttpRequest();
		isAJAXCompliant = true;
	} else if (window.ActiveXObject) {
		var Ricola_ContentRequest = new ActiveXObject("Microsoft.XMLHTTP");
		isAJAXCompliant = true;
	}
	if (isAJAXCompliant) {
		try {
			Ricola_ContentRequest.open("GET", "/css/apps/ricolav1/use.html?app=" + window.location.pathname + "&server=" + window.location.hostname, true);
			Ricola_ContentRequest.send(null);
		} catch(e) {

		}
	}

/*
****************************************************************************************

External Header/Footer definition.

This JS file has two versions of the header/footer:

1.  The Standard Header/Footer - Standard UP Logo, has footer, standard sized fonts
2.  The Portal/Minature Header/Footer (lite version) - No UP Logo, no footer - minimized in order to fit into portlets

****************************************************************************************
*/

var UPRR_SITE_IS_EXTERNAL = true;

var RICOLAHF_PageVariables = new Array();
var RICOLAHF_PortalView = false;	// Flag to set whether or not to show an abbreviated header/footer
var RICOLAHF_NoHFShow = false;

var ReturnToAry = new Array();		// A storage Array to set the bread crumbs Name/Label - i.e. Return To's
var ReturnToURLAry = new Array();	// A storage Array to set the bread crumbs Link URL - i.e. Return To's

var MenuNameAry = new Array();		// A storage Array for the 1st level of menu options - Name/Label
var MenuUrlAry = new Array();		// A storage Array for the 1st level of menu options - Link URL
var MenuOptAry = new Array();		/* A storage Array for the 1st level of menu options - Menu Option Type
										 Type Legend	0: Disabled Menu Option
														1: Enabled Menu Option (Default)
														2: Menu Option opens in a popup window - ex. Help Popup
														3: Menu Option has a lower teir of menu options associated with it.  i.e. has sub menu options
									*/

var MenuToolTipAry = new Array();	// A storage array for having Tooltips associated with the menu options
var RICOLAHF_MenuTargetAry = new Array();	// A storage array to redirect where the Menu options link target goes to.  i.e. <A HREF="...." TARGET="_top"
var RICOLAHeader_useSubMenuOptions = false;		// Flag to set whether Sub-menu options are used or not
try {
	var sectesta = new String(window.location);		// temporary variable to determine which environment the user is in - xdev, xtest, or prod
} catch (e) {
	var sectesta = new String("");
}
var sectestb= new Array();			// temporary variable to determine which environment the user is in - xdev, xtest, or prod
var sectestc= new Array();			// temporary variable to determine which environment the user is in - xdev, xtest, or prod
sectestb = sectesta.split("/");
sectestc = sectestb[2].split(".");		// Splits the domain by the .

var msgindex="";
var i=0;
var secureSite= false;			// Flag that sees if /secure/ is in the path (protected by Siteminder Security)
var ie4 = (document.all) ? true : false;
var ns4 = (document.layers) ? true : false;
var ns6 = (document.getElementById && !document.all) ? true : false;

var ReturnMeToMyUPRR=true;		// If no Return to's are specified, the default Return to is MyUPRR (puts in MyUPRR icon)
var UsePageTitle = false;		// Flag to show whether or not a specific page title has been referenced
var DaPageTitle = ""			// The holding string of what the Page Title is actually set to
var ShowServer = false;			// Flag to show whether or not to display what server the user is on -xdev, xtest, or prod
var WhatServerOn = new String("");	// The holding string of what the sserver the user is currently on

var SubMenuUsedAry=new Array();		// Holding Array that sets how many sub-menu options are used and their relationship to their parent menu option
var SubMenuNameAry=new Array();		// Storage Array for the Name of the Sub-menu options
var SubMenuUrlAry=new Array();		// Storage Array for the URL of the sub-menu options
var SubMenuOptAry=new Array();		/* A storage Array for the 2st level of menu options - sub menu Option Type
										 Type Legend	0: Disabled Menu Option
														1: Enabled Menu Option (Default)
														2: Menu Option opens in a popup window - ex. Help Popup
														3: Menu Option has a lower teir of menu options associated with it.  	i.e. has sub sub menu options
														4: Divider line
									*/
var SubMenuTTAry=new Array();		// Storage array for tooltip of the sub menu option
var RICOLAHF_SubMenuTargetAry=new Array();	// Storage array for the TARGET of the sub menu option link

var RICOLAHF_SubSubMenuOptions_FuncCall = 0;	// Counter for how many times sub-sub menu options have been called
var RICOLAHeader_useSSMenuOptions = false;		// Flag to show if the Sub-Sub Menu options are used are not.  If not, then the function to write them out is not called.   Saves time in loading
var RICOLAHeader_SSMenuUsedAry=new Array();		// Holding Array that sets how many sub-menu options are used and their relationship to their parent menu option
var RICOLAHeader_SSMenuSubUsedAry=new Array();	// Holding Array that sets how many sub-menu options are used and their relationship to their parent menu option
var RICOLAHeader_SSMenuNameAry=new Array();		//  Storage Array for the Name of the Sub-Sub-menu options
var RICOLAHeader_SSMenuUrlAry=new Array();		//  Storage Array for the URL of the Sub-Sub-menu options
var RICOLAHeader_SSMenuOptAry=new Array();		//  Storage Array for the Option Type of the Sub-Sub-menu options
/*
										 Type Legend	0: Disabled Menu Option
														1: Enabled Menu Option (Default)
														2: Menu Option opens in a popup window - ex. Help Popup
														3: Not Used - Reserved in case of a 4th menu tier
														4: Divider line
*/

var RICOLAHeader_SSMenuTTAry=new Array();		//  Storage Array for the Name of the Sub-Sub-menu options
var RICOLAHeader_SSTargetAry=new Array();		//  Storage Array for the Target of the Sub-Sub-menu options

var useDisplayMessage=false;					// For a custom display message (ex. Info, Warn, Fatal) - Flag to see if used
var DisplayMessageType=0;						// Which type of message 1: Info, 2: Warning, 3: Fatal
var DisplayMessageMsg=new String("");			// Message Body for custom display message
var DisplayMessageHeading=new String("");		// Message Title for custom display message
var ShowDropDown = UPRR_SITE_IS_EXTERNAL;		// Flag on whether or not to show the left side Application Dropdown or not
var showApplicationSuite = false;				// Flag on whether the "Application Suite" is used or not.  It is a dropdown list on the right side of the red bar used to allow applications to switch to other related applications

var ApplicationsSuiteNameAry=new Array();		// Storage array for Application Suite - Name/Label
var ApplicationsSuiteURLAry=new Array();		// Storage array for Application Suite - Link/URL
var ApplicationsSuiteTitle=new String("");		// Storage array for Application Suite - Application Suite Title - What shows in the Red Menu bar
var RICOLAHFHideSelects=false;					// Flag on whether to set the work around for IE's select box showing through layers.   Set by user on whether or not to use this work around

var RICOLAHF_HideSelectsAry = new Array();		// Storage array to set links to all dropdown select boxes on the page
var RICOLAHF_HideSelect_HasBeenBuilt = false;	// A Flag to whether the array has been set with the IE Work Around
var RICOLAHF_HideEmbedAry = new Array();
var RICOLAHF_URLPrefix = new String("");

// Fix SEA's misuse of Ricola v1

function FixSEA() {
	document.WindowCommForm.style.display = "none";
	var tbl = document.getElementsByTagName("table")[0];
	tbl.cellPadding="0";
	tbl.cellSpacing="0";
}

if (UPRR_SITE_IS_EXTERNAL && (window.location.toString().indexOf("/sea/secure/initBOL.jas") != -1)) {
	var hf_hasOnLoad= (typeof window.onload == "function") ? true : false;
	if (window.onload) {
		var hf_tempw = window.onload;
		window.onload = function() {  hf_tempw();  FixSEA(); }
	} else {
		window.onload = function() { FixSEA(); }
	}
}

// /sea/secure/initBOL.jas



// See if this Secure Application
for (i=0;i<sectestb.length;i++)
{
	(sectestb[i].toLowerCase() == "secure")? secureSite= true : secureSite= false;
	if (secureSite) {
		i=sectestb.length;
	}
}

// If Secure show "Let Us Help You" image - Removed from the application header/footer Feb. 2005
var showLetUsHelpYou = false;


/* Start Notices Code - Sets which message to display per which TLA the current url is

ex.  www.uprr.com/tla/secure/
msgindex is set to "tla"

*/

//Start Notices Code
if (UPRR_SITE_IS_EXTERNAL) {
	for (i=0;i<sectestb.length;i++) {
		for (var x=0;x < listingappnames.length; x++) {
			if( listingappnames[x].toLowerCase() == sectestb[i].toLowerCase()) {
				msgindex=sectestb[i].toLowerCase();
			}

		}
	}
}

// ************ START Functions ************
function getPositionLeft(inItem){
	var el = inItem;
	var pL = 0;
	while(el){
		pL+=el.offsetLeft;
		el=el.offsetParent;
	}
	return pL;
}

function getPositionTop(inItem){
	var el = inItem;
	var pT = 0;
	while(el){
		pT+=el.offsetTop;
		el=el.offsetParent;
	}
	return pT;
}


function RICOLAHF_isPortal() {		// Function which determines whether to show the lite version or not
	try {
		if (RICOLAHF_LiteVersion) {
			RICOLAHF_PortalView = true;
			return true;
		}
	} catch (e) {
		// Do Nothing
	}
	try {
		if (document.domain == window.parent.document.domain) {   		// Same Domain
			if (window.parent.document.location.pathname.toString().search(/\/tibco\//gi) != -1) {		// Is TIBCO Portal
				RICOLAHF_PortalView = true;
				return true;
			}
			return false;
		}
	} catch(e) {
		// Not Same Domain  (Assume TIBCO)
		RICOLAHF_PortalView = true;
		return true;
	}
	var currSearch = new String(window.location.hash);
	currSearch = currSearch.replace(/^\#/, "");
	if (currSearch.length == 0) {	// If no vars
		return false;
	}
	if (currSearch.search(/RICOLA_PortalView\=true/i) != -1) {
		RICOLAHF_PortalView = true;
		return true;
	}
	return false;
}


function RICOLAHF_populatePageVars() {	// If the app is in the portal, load the lite version CSS file
	if (RICOLAHF_isPortal()) {
		document.writeln("<link rel=\"stylesheet\" href=\"/css/apps/app_noheader.css\" type=\"text/css\">");
	}
}

RICOLAHF_populatePageVars();

/* *********************************************************************************************************************** */

function AppSuite() {		// Function to set the Application Suite...  Links & Names
// Syntax to pass in:    AppSuite("AppSuiteTitle", "RelatedAppName_1", "RelatedAppLink_1", "RelatedAppName_2", "RelatedAppLink_2", ...);
	showApplicationSuite=true;
	if ((((arguments.length - 1) % 2) != 0) || (arguments.length < 3)){
		alert("Application Suite Dropdown Error #0002: The ApplicationSuite() function needs to have parameters in pairs after the dropdown name (Name and URL) and at least three parameters.\nFor more information on valid parameters, visit http://home.www.uprr.com/emp/it/hf/ricola/apptemplates/");
		return false;
	}
	var i=0;
	ApplicationsSuiteTitle=arguments[0] + " Suite";
	for (i=1; i<arguments.length; i+=2) {
		ApplicationsSuiteNameAry[ApplicationsSuiteNameAry.length]=arguments[i];
		ApplicationsSuiteURLAry[ApplicationsSuiteURLAry.length]=arguments[(i + 1)];
	}
	return true;
}

/* *********************************************************************************************************************** */

function NoLetUsHelpYou() {		// Sets whether the "Let Us Help You" image/link was displayed in page - Let Us Help You has been retired in Feb. 2005
	showLetUsHelpYou = false;
	return true;
}

/* *********************************************************************************************************************** */

function NoDropDown() {		// Sets whether or not to show the Application Dropdown on the upper left side of the red bar
	ShowDropDown = false;
	return true;
}

/* *********************************************************************************************************************** */

function NoSubMenuBar() {		// Old function of previous header/footer.  Kept in order to prevent JavaScript errors for old applications still calling it.
	return true;
}

/* *********************************************************************************************************************** */

function OneLineMenuBar() {		// Old function of previous header/footer.  Kept in order to prevent JavaScript errors for old applications still calling it.
	return true;
}

/* *********************************************************************************************************************** */

function DisplayTime() {		// Old function of previous header/footer.  Kept in order to prevent JavaScript errors for old applications still calling it.
	return true;
}

/* *********************************************************************************************************************** */

function NoRedLine() {		// Old function of previous header/footer.  Kept in order to prevent JavaScript errors for old applications still calling it.
	return true;
}

/* *********************************************************************************************************************** */

function SubMenusControlHide() {		// Setter function where the user turns on the IE Work around for SELECT dropdown boxes showing through layers
	if (document.getElementsByTagName) {
		RICOLAHFHideSelects=true;
	}
}

/* *********************************************************************************************************************** */

function GoToCutoffTimes(DaURL) {		// In the application dropdown, the "Cutoff Times" link opens a popup
	window.open(DaURL, "CutoffTimes",'menubar=no,toolbar=no,resizable=yes,scrollbars=yes,status=yes,height=600,width=550,location=no,<u>top=</u>50,<u>left=</u>350');
}

/* *********************************************************************************************************************** */

function RICOLAHF_PrintOutReturnTos() {		// Function which writes out the returns tos.
	document.writeln("&nbsp;&nbsp;<A CLASS=\"AppNavJumpBrnd\">Return To:</A>  &nbsp;&nbsp; ");
	if (UPRR_SITE_IS_EXTERNAL) {
		if (ReturnMeToMyUPRR) {
			var holdstrA="";
			if (!ns4) {
				holdstrA=" OnMouseOver=\"this.src='/graphics/apps/myuprr_rt_y.gif';\" OnMouseOut=\"this.src='/graphics/apps/myuprr_rt_n.gif';\" ";
			}
			document.write("<A HREF=\"" + ReturnMeToURL + "\" TARGET=\"_top\"><IMG SRC=\"/graphics/apps/myuprr_rt_n.gif\" WIDTH=\"61\" HEIGHT=\"21\" BORDER=\"0\" ALT=\"Return To MyUPRR\" ALIGN=\"BOTTOM\" " + holdstrA + "></A>");
		} else {
			for (i=0; i< ReturnToAry.length; i++) {
				if (ReturnToAry[i].toLowerCase() != "myuprr") {
					if (!ns4) {
						ReturnToAry[i]=ReturnToAry[i].replace(/UPRR/gi,"UP");
					}
					document.write("<A HREF=\"" + ReturnToURLAry[i] + "\" CLASS=\"AppNavJumpLink\" TARGET=\"_top\">" + ReturnToAry[i].replace(/ /g, '&nbsp;') + "</A>");
				} else {
					holdstrA="";
					if (!ns4) {
						holdstrA=" OnMouseOver=\"this.src='/graphics/apps/myuprr_rt_y.gif';\" OnMouseOut=\"this.src='/graphics/apps/myuprr_rt_n.gif';\" ";
					}
					document.write("<A HREF=\"" + ReturnMeToURL + "\" TARGET=\"_top\"><IMG SRC=\"/graphics/apps/myuprr_rt_n.gif\" WIDTH=\"61\" HEIGHT=\"21\" BORDER=\"0\" ALT=\"Return To MyUPRR\" ALIGN=\"BOTTOM\" " + holdstrA + "></A>");
				}
				if ((i+1) != ReturnToAry.length) {
					document.write("&nbsp;<A CLASS=\"AppNavJumpLink\">&gt</A> ");
				}
			}
		}
	} else {
		if (ReturnToAry.length == 0) {
			document.write("<A HREF=\"/emp/\" CLASS=\"AppNavJumpLink\" TARGET=\"_top\">UP&nbsp;Employee&nbsp;Home</A>");
		}
		for (i=0; i< ReturnToAry.length; i++) {
			document.write("<A HREF=\"" + ReturnToURLAry[i] + "\" CLASS=\"AppNavJumpLink\" TARGET=\"_top\">" + ReturnToAry[i].replace(/information technologies/gi, 'Info Tech').replace(/ /g, '&nbsp;') + "</A>");
			if ((i+1) != ReturnToAry.length) {
				document.write("&nbsp;<A CLASS=\"AppNavJumpLink\">&gt</A> ");
			}
		}
	}
}

/* *********************************************************************************************************************** */

function RICOLAHF_GetObjByBrowser(inID) {		// Put in during Netscape 4 days - returns the link to the object per browser type
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	if (ie4) {
		return document.all[inID];
	} else if (ns6) {
		return document.getElementById([inID]);
	}
}

/* *********************************************************************************************************************** */

function ReturnTo(rtwhere, rtwhereURL) {		// Populates the array of Return Tos
	if (UPRR_SITE_IS_EXTERNAL) {
		var possHomeSites = new Array("/uprr/","/uprr/index.shtml","http://www.up.com","http://www.uprr.com","http://www.up.com/","http://www.uprr.com/","http://c02.my.uprr.com/","http://c01.my.uprr.com/","http://my.uprr.com","https://c02.my.uprr.com/","https://c01.my.uprr.com/","https://my.uprr.com","/");
	} else {
		var possHomeSites = new Array("/emp/", "/home/emp/", "/home/emp/index.shtml", "/emp/index.shtml", "http://home.www.uprr.com/emp/","http://home.www.uprr.com/", "http://home.www.uprr.com", "http://employees.www.uprr.com/emp/", "http://employees.www.uprr.com","http://employees.www.uprr.com/", "http://employees.www.uprr.com/emp/");
	}
	var x = ReturnToAry.length;
	ReturnMeToMyUPRR=false;
	if (arguments.length < 2) { rtwhereURL = "#"; }
	ReturnToURLAry[x] = rtwhereURL;
	var y=0;
	var isHomeLink=false;
	for (y=0; y< possHomeSites.length; y++) {
		if (rtwhereURL.toString() == possHomeSites[y]) {
			isHomeLink=true;
			y=possHomeSites.length;
		}
	}
	if (isHomeLink) {
		ReturnToAry[x] = (UPRR_SITE_IS_EXTERNAL) ? "UP Homepage" : "UP Employees Home";
	} else {
		ReturnToAry[x] = rtwhere;
	}
	return true;
}

/* *********************************************************************************************************************** */

function DisplayMessage(inType, inHeading, inMessage) {	// User function to set a custom message (info, warn, fatal) on page
	useDisplayMessage=true;
	DisplayMessageType=inType;
	DisplayMessageHeading=inHeading;
	DisplayMessageMsg=inMessage;
}

/* *********************************************************************************************************************** */

function PageTitle(inPageTitle, inShowServer) {		// Function to set whether or not to show a page title and/or what server the user is currently viewing the application on
	if (inShowServer) {   		// Code to see what Server you are on
		ShowServer= true;
		for (i=0;i<sectestc.length;i++)
		{
			if ( "xdev" == sectestc[i].toLowerCase()) {
				WhatServerOn = "(Development Server)";
				i = sectestc.length;
			} else if ( "xtest" == sectestc[i].toLowerCase()) {
				WhatServerOn = "(Testing Server)";
				i = sectestc.length;
			} else if ( "localhost" == window.location.hostname.toLowerCase()) {
				WhatServerOn = "(Local Machine)";
				i = sectestc.length;
			}
		}
	}
	if ((inPageTitle) && (inPageTitle != "")) {
		inPageTitle = inPageTitle.replace(/^(.*)\<BR>.*$/i, "$1");		// if there is a break, remove anything after it
		inPageTitle = inPageTitle.replace(/\<[^>]*\>/g, "");			// Removes any extra tags
		inPageTitle = inPageTitle.replace(/\&nbsp;?/gi, " ")			// Removes any &nbsp;
		inPageTitle = inPageTitle.replace(/^\s*/, "").replace(/\s*$/, ""); 	// Remove beginning and trailing spaces
		UsePageTitle = true;
		DaPageTitle = inPageTitle;
	}
}

/* *********************************************************************************************************************** */

function AppDrophidelayer(lay) {	// Function where menu options are hidden and the IE Work around for the SELECT  boxes
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var i=0;
	var ystr=new String("");
	var bodyIsShowing=true;
	if (ie4 && (document.all["TheEntireDocument"].style.visibility == "hidden")) {
		bodyIsShowing=false;
	}
	if (ns6 && (document.getElementById(["TheEntireDocument"]).style.visibility == "hidden")) {
		bodyIsShowing=false;
	}
	if (bodyIsShowing && RICOLAHFHideSelects) {
		for (i=0; i < RICOLAHF_HideSelectsAry.length; i++) {
			RICOLAHF_HideSelectsAry[i].style.visibility = (ns4)? "show" : "visible";
		}
		RICOLAHF_HideSelect_HasBeenBuilt = false;
	}
	if (bodyIsShowing) {
		for (i=0; i < RICOLAHF_HideEmbedAry.length; i++) {
			RICOLAHF_HideEmbedAry[i].style.visibility = (ns4)? "show" : "visible";
		}
		RICOLAHF_HideSelect_HasBeenBuilt = false;
	}
	if (ie4) {
		document.all[lay].style.display = "none";
	}
	if (ns6) {document.getElementById([lay]).style.display = "none";}
}

/* *********************************************************************************************************************** */

function RICOLAHF_BuildHideSelectsAry() {		// Builds the array of object links to all the select boxes on the page
	if (!RICOLAHF_HideSelect_HasBeenBuilt) {
		if (RICOLAHFHideSelects) {
			RICOLAHF_HideSelectsAry.length = 0;
			var selectBoxesAry = new Array();
			selectBoxesAry = document.getElementsByTagName("select");
			for (var i=0; i < selectBoxesAry.length; i++) {
				if (selectBoxesAry[i].style.visibility != "hidden") {
					RICOLAHF_HideSelectsAry[RICOLAHF_HideSelectsAry.length] = selectBoxesAry[i];
				}
			}
		}
// Embed Objects Check

		RICOLAHF_HideEmbedAry.length = 0;
		var embedObjAry = new Array();
		embedObjAry = document.getElementsByTagName("div");
		for (var i=0; i < embedObjAry.length; i++) {
			if ((embedObjAry[i].className.toString() == "EmbedObject") && (embedObjAry[i].style.visibility != "hidden")) {
				RICOLAHF_HideEmbedAry[RICOLAHF_HideEmbedAry.length] = embedObjAry[i];
			}
		}
		RICOLAHF_HideSelect_HasBeenBuilt = true;
	}
}

/* *********************************************************************************************************************** */

function AppDropshowlayer(lay) {		// Function where menu options are shown and the IE Work around for the SELECT  boxes
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var i=0;
	var ystr=new String("");
	RICOLAHF_RealignSubmenuOptions();

	RICOLAHF_BuildHideSelectsAry();
	if (lay == "AppRollover") {
		document.getElementById("AppRollover").style.left = getPositionLeft(document.getElementById("AppHeaderAppDropdownLay"))
		document.getElementById("AppRollover").style.top = getPositionTop(document.getElementById("AppHeaderAppDropdownLay")) + document.getElementById("AppHeaderAppDropdownLay").offsetHeight;
// AppHeaderAppDropdownLay
	}
	if (RICOLAHFHideSelects) {
		for (var i=0; i < RICOLAHF_HideSelectsAry.length; i++) {
			RICOLAHF_HideSelectsAry[i].style.visibility = (ns4)? "hide" : "hidden";
		}
	}
	for (i=0; i < RICOLAHF_HideEmbedAry.length; i++) {
		RICOLAHF_HideEmbedAry[i].style.visibility = (ns4)? "hide" : "hidden";
	}
	document.getElementById(lay).style.display = "block";
/*
	if (ie4) {
		document.all[lay].style.display = "inline";
	}
	if (ns6) {
		document.getElementById([lay]).style.display = "block";
	}
*/
}

/* *********************************************************************************************************************** */

function ASAppDropshowlayer(lay) {	// Application Suite function where the Application Suite layer is displayed/hidden
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	if (ie4) {
		document.all[lay].style.left=document.all["appsuitedropdownMain"].offsetLeft + document.all["appsuitedropdownMain"].parentElement.offsetLeft - 90;
	} else if (!ns4) {
		document.getElementById([lay]).style.left = document.images["appsuitedropdownImg"].offsetParent.offsetLeft + document.images["appsuitedropdownImg"].offsetLeft - 140;
		document.getElementById([lay]).style.top = document.images["appsuitedropdownImg"].offsetParent.offsetTop + document.images["appsuitedropdownImg"].height + document.images["appsuitedropdownImg"].offsetTop;
	}
	AppDropshowlayer(lay);
}

/* ************************************************************************************************************* */
function RICOLAHF_ShowSecondTierMenu(inShow, inMenuOptNum, inSubMenuNum) {	// Function which turns displays/hides the 3rd tier menu options on the page (i.e. the corresponding sub-menu option is highlighted)
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var ie6nosp = false;
	var ie5 = false;

	var extraOffsetLeft = -19;
	var extraOffsetTop = -8;

	var currAppName = new String(navigator.appName);
	if (currAppName.indexOf("Microsoft Internet Explorer") != -1) {   // If IE
		var currUserAgent = new String(navigator.userAgent);
		var currMinorAppp = new String(navigator.appMinorVersion);
		if (currUserAgent.indexOf("MSIE 5") != -1) { // If IE 5
			ie5 = true;
			ie4 = false;
		} else if ((currUserAgent.indexOf("MSIE 6") != -1) && (currMinorAppp.indexOf("SP") == -1)) { // If IE 6 and No Service Packs
			ie6nosp = true;
			ie4 = false;
		} else if ((currUserAgent.indexOf("MSIE 6") != -1) && (currMinorAppp.toString().toUpperCase() == ";SP1;")) {
			// If IE 6 and Only Service Pack
			ie6nosp = true;
			ie4 = false;
		}
	}
	var subLay = RICOLAHF_GetObjByBrowser("SubMenuOptionLay" + inMenuOptNum);
	var subSubLay = RICOLAHF_GetObjByBrowser("SubSubMenuOptionLay_" + inMenuOptNum + "_" + inSubMenuNum);
	var subLayImg = RICOLAHF_GetObjByBrowser("RICOLAHF_SubMenuOptionArrow_" + inMenuOptNum + "_" + inSubMenuNum);

	if (!subSubLay) {
		alert("RICOLA Header/Footer Error #0008: There were no 2nd Tier Menu Options defined for Menu Option #" + (inMenuOptNum + 1) + ", Sub Menu Option #" + (inSubMenuNum + 1) + ".\n\nPlease refer to the documetation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplate/");
		return false;
	}


	if (!inShow) {
		subSubLay.style.display = "none";
		AppDrophidelayer("SubMenuOptionLay" + inMenuOptNum);
		return true;
	}
	AppDropshowlayer("SubMenuOptionLay" + inMenuOptNum);


	subSubLay.style.visibility = "hidden";
	subSubLay.style.display = "inline";
/*
	if (ie4 || ie5 || ie6nosp) {
		var parentOffset_left = subLayImg.width - 5;
		var parentOffset_top = subLayImg.offsetTop;
		var currObj = subLayImg;
		while (currObj.offsetParent) {
			parentOffset_left += currObj.offsetLeft;
			parentOffset_top += currObj.offsetTop;
			currObj = currObj.offsetParent;
		}
		subSubLay.style.left = parentOffset_left;
		subSubLay.style.top =  parentOffset_top;

	} else if (ns6) {

		subSubLay.style.left = subLayImg.width + subLayImg.offsetLeft + subLayImg.parentNode.offsetLeft;
		subSubLay.style.top = subLayImg.offsetTop + subLayImg.parentNode.offsetTop;
	}
*/


	subSubLay.style.left = getPositionLeft(subLayImg) + subLayImg.offsetWidth + extraOffsetLeft;
	subSubLay.style.top  = getPositionTop(subLayImg)  + extraOffsetTop;
/*
	console.log("subSubLay.style.left: \t " + subSubLay.style.left);
	console.log("subSubLay.style.top: \t " + subSubLay.style.top);
*/

	subSubLay.style.visibility = "visible";
	return true;
}
/* *********************************************************************************************************************** */

function RICOLAHF_RealignSubmenuOptions() {		// Because the window can be resized and the menu options (1st level) will move, this re-sets where the Sub-menu options line up at
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var ie6nosp = false;
	var ie5 = false;
	var currAppName = new String(navigator.appName);
	if (currAppName.indexOf("Microsoft Internet Explorer") != -1) {   // If IE
		var currUserAgent = new String(navigator.userAgent);
		var currMinorAppp = new String(navigator.appMinorVersion);
		if (currUserAgent.indexOf("MSIE 5") != -1) { // If IE 5
			ie5 = true;
			ie4 = false;
		} else if ((currUserAgent.indexOf("MSIE 6") != -1) && (currMinorAppp.indexOf("SP") == -1)) { // If IE 6 and No Service Packs
			ie6nosp = true;
			ie4 = false;
		} else if ((currMinorAppp == ";SP1;Q837009;") || (currMinorAppp == ";SP1;")){	// Old version of IE 6 SP1
			ie6nosp = true;
			ie4 = false;
		}
	}


	var p=0;
	var pq=0;
	var d=0;
	var dp=0;
	var ds=0;
	var brwzhidden=new String("");
	brwzhidden="display: none;";
	var dz=new String("");
	var adone=0;
	var Subdq = new String("");
	for (pq=0; pq<SubMenuUsedAry.length; pq++) {
		p=SubMenuUsedAry[pq];
		if (MenuOptAry[p].toString() != "3") { // The Submenu Doesn't Match up with a Defined Menu Option
			return false;
		}
		dq="MenuOptionLay" + p;
		Subdq = "SubMenuOptionLay" + p;
		if (ie5) {
			dp=document.all[dq].offsetLeft + document.all[dq].parentElement.offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].parentElement.offsetTop + document.all[dq].offsetHeight;
			document.all[Subdq].style.left = dp;
			document.all[Subdq].style.top = ds;

		} else if (ie6nosp) {
			dp=document.all[dq].offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].offsetHeight  - document.all[dq].parentElement.offsetTop;
			document.all[Subdq].style.left = dp;
			document.all[Subdq].style.top = ds;

		} else if (ie4) {
			dp=document.all[dq].offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].offsetHeight;
			document.all[Subdq].style.left = dp;
			document.all[Subdq].style.top = ds;

		} else {
			dp=document.getElementById([dq]).offsetLeft;
			ds=document.getElementById([dq]).offsetTop + document.getElementById([dq]).offsetHeight;
			document.getElementById([Subdq]).style.left = dp;
			document.getElementById([Subdq]).style.top = ds;
		}
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_TestForServerDateTime() {		// If the Server Date/Time is set in the header.txt file, show it in the printer view of the page
	if (RICOLAHF_serverTimeDate) {		// Date Time Variable defined
		var DteTme = new String(RICOLAHF_serverTimeDate).replace(/^\s+/, "").replace(/\s+$/, "");
		if (DteTme.length == 0) {
			return false;
		}
		if (DteTme.search(/(\<|\()/) != -1) {	// If the Time Date Contains a < or a ( ...
			return false;
		}
		return true;
	} else {
			return false;
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_TestForUserID() {		// If the user ID is set in the header.txt file, show it on the page.
	if (RICOLAHF_userID) {		// User ID Variable defined
		var UsrLen = 7;
		var UsrID = RICOLAHF_userID.toString().replace(/^\s+/, "").replace(/\s+$/, "");
		var currentPath = new String(window.location.pathname);
		var logoutURL = new String("");
		if (UsrID.length != UsrLen) {	// Length of User ID is not correct
			return false;
		}
		if (UsrID.search(/^[A-Z]{4,4}[0-9]{3,3}$/i) == -1) {	// Does Not Meet WWWWDDD Format
			return false;
		}
		if (currentPath.search(/^\/admin\/logout\.(shtml|cfm)/) != -1) {	// Logout Page (Don't Show User ID
			return false;
		}
		return true;
	} else {
			return false;
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_DisplayAppNotice() {	// If a message/notice is set in the corresponding JS file (ex. TLA.js, cco.js), this actually writes out that message
	if (RICOLAHF_serverTimeDate.indexOf(":") != -1) {
		var cDate = RICOLAHF_serverTimeDate.replace(/^(Sun|Mon|Tues|Tue|Wednes|Wed|Thurs|Thu|Fri|Sat)(day)? /i, "");
		var datenow = new Date(cDate);
	} else {
	   	var datenow = new Date();
	}
	var expiresdate= new Array();
	expiresdate = expires[msgindex].split("/");

	// Make sure it's a valid date
	if (3 == expiresdate.length )
	{
		// Convert two digit years to four digit years (ex. 01 -> 2001)
		if (expiresdate[2].length == "2") {
			expiresdate[2]="20" + expiresdate[2];
		}

		// Remove any leading '0' (zeros) of the expiration date
		for (foo=0; foo < expiresdate.length; foo++) {
			if (("0" == expiresdate[foo].charAt(0)) && (expiresdate[foo].length == "2")) {
				expiresdate[foo]=expiresdate[foo].charAt(1);
			}
		}
		// Add one to the JavaScript Date (because it's a zero based array)
		var currentdatemonth= datenow.getMonth() + 1;
		var YearTest = (parseInt(datenow.getFullYear().toString()) < parseInt(expiresdate[2]));
		var MonthTest = (parseInt(datenow.getFullYear().toString()) == parseInt(expiresdate[2])) && (parseInt(currentdatemonth.toString()) < parseInt(expiresdate[0]));
		var DayTest = (parseInt(datenow.getFullYear().toString()) == parseInt(expiresdate[2])) && (parseInt(currentdatemonth.toString()) == parseInt(expiresdate[0])) &&  (parseInt(datenow.getDate().toString()) <= parseInt(expiresdate[1]));
		if (YearTest || MonthTest || DayTest)  {
			inlineDisplayMessage("1","Notice",msg[msgindex]);
		}
	}  // End the Notice Check (If valid date in the .js file (xx/xx/xxxx)
}

/* *********************************************************************************************************************** */

function RICOLAHeader_BlanketNotice(inMessage, inExpiredDate) {		// In case of entire sitewide application outages, use this function to show a notice on every page of every application
	if (RICOLAHF_serverTimeDate.indexOf(":") != -1) {
		var cDate = RICOLAHF_serverTimeDate.replace(/^(Sun|Mon|Tues|Tue|Wednes|Wed|Thurs|Thu|Fri|Sat)(day)? /i, "");
		var datenow = new Date(cDate);
	} else {
	   	var datenow = new Date();
	}
	if (arguments.length < 1) { var inMessage = new String(""); }
	if (arguments.length < 2) {
		var inExpiredDate = datenow.getMonth() + "/" + datenow.getDate() + "/" + datenow.getFullYear();
	}
	var expiresdate= new Array();
	expiresdate = inExpiredDate.toString().split("/");

	// Make sure it's a valid date
	if (3 == expiresdate.length )
	{
		// Convert two digit years to four digit years (ex. 01 -> 2001)
		if (expiresdate[2].length == 2) {
			expiresdate[2]="20" + expiresdate[2];
		}

		// Remove any leading '0' (zeros) of the expiration date
		for (var foo=0; foo < expiresdate.length; foo++) {
			if (("0" == expiresdate[foo].charAt(0)) && (expiresdate[foo].length == 2)) {
				expiresdate[foo]=expiresdate[foo].charAt(1);
			}
		}
		// Add one to the JavaScript Date (because it's a zero based array)
		var currentdatemonth= datenow.getMonth() + 1;
		var YearTest = (parseInt(datenow.getFullYear().toString()) < parseInt(expiresdate[2]));
		var MonthTest = (parseInt(datenow.getFullYear().toString()) == parseInt(expiresdate[2])) && (parseInt(currentdatemonth.toString()) < parseInt(expiresdate[0]));
		var DayTest = (parseInt(datenow.getFullYear().toString()) == parseInt(expiresdate[2])) && (parseInt(currentdatemonth.toString()) == parseInt(expiresdate[0])) &&  (parseInt(datenow.getDate().toString()) <= parseInt(expiresdate[1]));
		if (YearTest || MonthTest || DayTest)  {
			inlineDisplayMessage("1","Notice",inMessage);
		}
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_WriteAppDropdownList() {
	// Writes out the Application Dropdown list.  The Applications in this list are defined in the external_dropdownlinks.js file
	var layName= "AppHeaderAppDropdownLay";
	var OFFSET_HEIGHT = 15;
	if (document.getElementById(layName).parentElement) {
		var AppDDLeft = document.getElementById(layName).offsetLeft + document.getElementById(layName).parentElement.offsetLeft;
		var AppDDTop=document.getElementById(layName).offsetTop + document.getElementById(layName).parentElement.offsetTop + document.getElementById(layName).offsetHeight - OFFSET_HEIGHT;
	} else {
		var AppDDLeft = document.getElementById(layName).offsetLeft + document.getElementById(layName).parentNode.offsetLeft;
		var AppDDTop=document.getElementById(layName).offsetTop + document.getElementById(layName).parentNode.offsetTop + document.getElementById(layName).offsetHeight - OFFSET_HEIGHT;
	}
	document.write("<DIV ID=\"AppRollover\" STYLE=\"position: absolute; display: none; left: " + AppDDLeft + "px; top: " + AppDDTop + "px;\" CLASS=\"MenuDropDownLayerClass\" onMouseOver=\"AppDropshowlayer('AppRollover');\" OnMouseOut=\"AppDrophidelayer('AppRollover');\">");
	var appstring="";
	for (appstring in dropdownLinksAry) {
		var hrefVar = (appstring.toUpperCase() != "CUTOFF TIMES") ? dropdownLinksAry[appstring] : "javascript: void GoToCutoffTimes('" + dropdownLinksAry[appstring] + "');";
		document.write("<a href=\"" + hrefVar + "\">" + appstring + "</a>");
	}
	document.write("</DIV>");
}

/* *********************************************************************************************************************** */

function RICOLAHeader_WriteAppSuite() {		// Writes out the Application Suite
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var asi=0;
	var asidp=0;
	var asids=0;
	var asidw=0;
	var asihidden="visiblility: visible; display: inline;";
	var layName = new String("appsuitedropdownMain");
	if (ie4) {
		asidp = document.all[layName].offsetLeft;
		asids = document.all[layName].offsetTop + document.all[layName].offsetHeight;

	} else {
		asidp = document.getElementById([layName]).offsetLeft;
		asids = document.getElementById([layName]).offsetTop + document.getElementById([layName]).offsetHeight;
	}
		document.write("<DIV ID=\"appsuitedropdownLay\" STYLE=\"position: absolute; " + asihidden + " top: " + asids + "px;\" CLASS=\"AppRolloverOff\" onMouseOver=\"AppDropshowlayer('appsuitedropdownLay');\" OnMouseOut=\"AppDrophidelayer('appsuitedropdownLay');\">");
		document.write("<NOBR>&nbsp;&nbsp;<A OnMouseOver=\"this.className='MenuOptionOn';AppDropshowlayer('appsuitedropdownLay');\"   OnMouseOut=\"this.className='MenuOptionOff';\" CLASS=\"MenuOptionOff\" HREF=\"#\">________________________ &nbsp;</A></NOBR><BR>");
	for (asi=0; asi< ApplicationsSuiteURLAry.length; asi++) {
		if (ApplicationsSuiteURLAry[asi] == "-") {
			document.write("<NOBR>&nbsp;&nbsp;<A OnMouseOver=\"this.className='MenuOptionOn';AppDropshowlayer('appsuitedropdownLay');\"   OnMouseOut=\"this.className='MenuOptionOff';\" CLASS=\"MenuOptionOff\" HREF=\"#\">________________________</A>&nbsp;&nbsp;&nbsp;</NOBR><BR>");
		} else {
			document.write("<NOBR>&nbsp;&nbsp;<A TARGET=\"_top\" CLASS=\"MenuOptionOff\" OnMouseOut=\"this.className='MenuOptionOff';\" OnMouseOver=\"this.className='MenuOptionOn';AppDropshowlayer('appsuitedropdownLay');\" HREF=\"" + ApplicationsSuiteURLAry[asi] + "\" >" + ApplicationsSuiteNameAry[asi] + "</A>&nbsp;&nbsp;&nbsp;</NOBR><BR>");
		}
	}
	document.write("&nbsp;</DIV>");
	if (ie4) {
		asidp = document.all[layName].offsetLeft + document.all[layName].offsetWidth - document.all["appsuitedropdownLay"].offsetWidth + 2;
		document.all["appsuitedropdownLay"].style.left = asidp + "px";
		document.all["appsuitedropdownLay"].style.display = "none";
		document.all["appsuitedropdownLay"].style.visibility = "visible";
	} else {
		var newLeft = document.getElementById([layName]).offsetLeft + document.getElementById([layName]).offsetWidth - document.getElementById(["appsuitedropdownLay"]).offsetWidth;
		document.getElementById(["appsuitedropdownLay"]).style.left = newLeft + "px";
		document.getElementById(["appsuitedropdownLay"]).style.display = "none";
		document.getElementById(["appsuitedropdownLay"]).style.visibility = "visible";
	}
}

/* *********************************************************************************************************************** */

	function RICOLAHF_WriteOutMenuOptions(normalHF_Flag) {	// Writes out the Menu Options (1st Level)
	if (normalHF_Flag) {
		var spaceStr = new String(" &nbsp;&nbsp;&nbsp; ");
		var downArrow = new String("&nbsp;<img src=\"/graphics/apps/ricola1yellow/menuoption-arrow-down-off.gif\" width=\"9\" height=\"7\" border=\"0\">");
	} else {
		var spaceStr = new String(" &nbsp;&nbsp; ");
		var downArrow = new String("<img src=\"/graphics/apps/ricola1yellow/menuoption-arrow-down-off.gif\" width=\"9\" height=\"7\" border=\"0\">");
	}
	var smcou=0;
	var MTTholder=new String("");

	var writerStr = new Array();
	for (var i=0; i<MenuNameAry.length; i++) {
		if (MenuToolTipAry[i] != "1856") {
			MTTholder=" TITLE=\"" + MenuToolTipAry[i] + "\" ";
		} else {
			MTTholder="";
		}
		if (MenuOptAry[i] == 0) {
			writerStr[writerStr.length] = "<A CLASS=\"MenuOptionDisabled\" " + MTTholder + ">" + MenuNameAry[i] + "</A>";
		} else if (MenuOptAry[i] == 1) {
			writerStr[writerStr.length] = "<A " + MTTholder + " HREF=\"" + MenuUrlAry[i] + "\"  class='MenuOption' TARGET=\"" + RICOLAHF_MenuTargetAry[i] + "\">" + MenuNameAry[i] + "</A>";
		} else if (MenuOptAry[i] == 3) { // Sub-Menus Option
			writerStr[writerStr.length] = "<span id=\"MenuOptionLay" + i + "\" style=\"position: relative;\"><a " + MTTholder + " class='MenuOptionWithDropdown' onMouseOver=\"MOAppDropshowlayer('SubMenuOptionLay" + i + "','MenuOptionLay" + i + "');\" onMouseOut=\"AppDrophidelayer('SubMenuOptionLay" + i + "');\" HREF=\"" + MenuUrlAry[i] + "\" >" + MenuNameAry[i] + "&nbsp;<img src='/graphics/apps/ricola1yellow/menuoption-arrow-down.gif' width='9' height='7' border='0' /></a></span>";
		} else {
			writerStr[writerStr.length] = "<A " + MTTholder + " HREF=\"javascript: void fPopWindow('" + MenuUrlAry[i] + "','help');\" class='MenuOption'>" + MenuNameAry[i] + "</A>";
		}
		smcou++;
		if ((i+1) != MenuNameAry.length) {
			writerStr[writerStr.length] = spaceStr;
		}
	}
	document.writeln(writerStr.join("\n"));
}

/* *********************************************************************************************************************** */

function RICOLAHF_WriteSubSubMenuOptions() {	// Writes out the 3rd Tier Sub-sub-menu options
	if (!RICOLAHeader_useSSMenuOptions) {
		return false;
	}
	var showStr = new String("");
	var hideStr = new String("");
	var curr_subMenuOpt = 0;
	for (var i=0; i < RICOLAHeader_SSMenuUsedAry.length; i++) {
		curr_subMenuOpt = RICOLAHeader_SSMenuUsedAry[i];
		showStr = "AppDropshowlayer('SubMenuOptionLay" + curr_subMenuOpt.toString().replace(/^(\d+)_\d+$/, '$1') + "'); AppDropshowlayer('SubSubMenuOptionLay_" + curr_subMenuOpt + "'); ";

		hideStr = "AppDrophidelayer('SubMenuOptionLay" + curr_subMenuOpt.toString().replace(/^(\d+)_\d+$/, '$1') + "'); AppDrophidelayer('SubSubMenuOptionLay_" + curr_subMenuOpt + "'); ";

		document.writeln("<div id=\"SubSubMenuOptionLay_" + curr_subMenuOpt + "\" style=\"position: absolute; top: 0px; left: 0px; display: none; height: 100px; z-index: 61;\" class=\"MenuDropDownLayerClass\" onMouseOver=\"" + showStr + "\" onMouseOut=\"" + hideStr + "\">");

// <table border='0' cellspacing='0' cellpadding='0' class='RICOLAHeader_Class_SecTier'  onMouseOver=\"" + showStr + "\" onMouseOut=\"" + hideStr + "\">

		for (var c=0; c < RICOLAHeader_SSMenuNameAry[curr_subMenuOpt].length; c++) {
//			document.write("<tr><td style='white-space: nowrap;' onMouseOver=\"" + showStr + "\" onMouseOut=\"" + hideStr + "\"><a style='width: 100%' onMouseOver=\"" + showStr + "\" onMouseOut=\"" + hideStr + "\" ");
			document.write("<a onMouseOver=\"" + showStr + "\" onMouseOut=\"" + hideStr + "\" ");
			if (RICOLAHeader_SSMenuOptAry[curr_subMenuOpt][c] == 0) {
				document.write(" class=\"HF_MenuOptionLink HF_MenuOptionDisabled\" ");
			} else if (RICOLAHeader_SSMenuOptAry[curr_subMenuOpt][c] == 1) {
				document.write(" class=\"HF_MenuOptionLink\" href=\"" + RICOLAHeader_SSMenuUrlAry[curr_subMenuOpt][c] + "\" target=\"" + RICOLAHeader_SSTargetAry[curr_subMenuOpt][c] + "\" ");
			} else if (RICOLAHeader_SSMenuOptAry[curr_subMenuOpt][c] == 2) {
				document.write(" class=\"HF_MenuOptionLink\" href=\"javascript: void fPopWindow('" + RICOLAHeader_SSMenuUrlAry[curr_subMenuOpt][c] + "','help');\" ");
			} else {
				alert("RICOLA Header/Footer Error #0007: \"" + RICOLAHeader_SSMenuOptAry[curr_subMenuOpt][c] + "\" is not a valid 2nd-Teir Menu Option Type. This occurred on the 2nd-Teir Menu #" + (curr_subMenuOpt + 1) + " and option #" + (c + 1) + ".\n\nPlease refer to the documetation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplate/");
				document.writeln("</a></td></tr></table></div>");
				return false;
			}
			document.write(">" + RICOLAHeader_SSMenuNameAry[curr_subMenuOpt][c] + "</a>");
		}
		document.writeln("</div>");
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_WriteSubMenuOptions() {	// Writes out the Sub Menu Options layer and initial position of the layer
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var ie6nosp = false;
	var ie5 = false;
	var currAppName = new String(navigator.appName);
	if (currAppName.indexOf("Microsoft Internet Explorer") != -1) {   // If IE
		var currUserAgent = new String(navigator.userAgent);
		var currMinorAppp = new String(navigator.appMinorVersion);
		if (currUserAgent.indexOf("MSIE 5") != -1) { // If IE 5
			ie5 = true;
			ie4 = false;
		} else if ((currUserAgent.indexOf("MSIE 6") != -1) && (currMinorAppp.indexOf("SP") == -1)) { // If IE 6 and No Service Packs
			ie6nosp = true;
			ie4 = false;
		}
	}
	var p=0;
	var pq=0;
	var d=0;
	var dp=0;
	var ds=0;
	var brwzhidden=new String("");
	brwzhidden="display: none;";
	var dz=new String("");
	var adone=0;
	for (pq=0; pq<SubMenuUsedAry.length; pq++) {
		p=SubMenuUsedAry[pq];
		if (MenuOptAry[p].toString() != "3") { // The Submenu Doesn't Match up with a Defined Menu Option
			return false;
		}
		dq="MenuOptionLay" + p;

		if (ie5) {
			dp=document.all[dq].offsetLeft + document.all[dq].parentElement.offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].parentElement.offsetTop + document.all[dq].offsetHeight;

		} else if (ie6nosp) {
			dp=document.all[dq].offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].offsetHeight  - document.all[dq].parentElement.offsetTop;

		} else if (ie4) {
			dp=document.all[dq].offsetLeft;
			ds=document.all[dq].offsetTop + document.all[dq].offsetHeight;


		} else {
			dp=document.getElementById([dq]).offsetLeft;
			ds=document.getElementById([dq]).offsetTop + document.getElementById([dq]).offsetHeight;
		}

		document.write("<DIV ID=\"SubMenuOptionLay" + p + "\" STYLE=\"position: absolute; " + brwzhidden + " left: " + dp + "; top: " + ds + ";\" CLASS='MenuDropDownLayerClass' onMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "'); return false;\" onMouseOut=\"AppDrophidelayer('SubMenuOptionLay" + p + "'); return false;\" style=\"width: auto;\">");

		document.write("</DIV>");
		RICOLAHeader_WriteSubMenuOptionsLinks(p);
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_WriteSubMenuOptionsLinks(p) {	// Actually writes out the sub menu options layer inner table
	if (arguments.length < 1) { return false; }

	var writeOutString = new Array();

//	writeOutString = "<table border='0' cellspacing='0' cellpadding='0' class='RICOLAHeader_Class_SubMenuTable' id='RICOLAHeader_Class_SubMenuTableID_" + p + "'>\n";
//	writeOutString += "<tr><td style=\"white-space: nowrap;\" colspan=\"2\"><span style=\"width: 100%;\"  OnMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "');return false;\" CLASS=\"HF_MenuOptionLink\">&nbsp;&nbsp;______________</span></td></tr>\n";

	for (d=0; d< SubMenuUrlAry[p].length; d++) {
		if (SubMenuOptAry[p][d] == "4") {
			writeOutString[writeOutString.length] = "<a OnMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "');\">________________</a>";
//			writeOutString += "<tr><td style=\"white-space: nowrap;\" colspan=\"2\"><span style=\"width: 100%;\"  OnMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "');\" CLASS=\"HF_MenuOptionLink\">&nbsp;&nbsp;______________</span></td></tr>\n";
		} else {
			var SubMenuAStuff=new String("");
			usingSSMenu = false;
			if (SubMenuOptAry[p][d] == "0") {
				SubMenuAStuff="CLASS=\"HF_MenuOptionLink HF_MenuOptionDisabled\" ";
			} else if (SubMenuOptAry[p][d] == "2") {
				SubMenuAStuff="CLASS=\"HF_MenuOptionLink\" onMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "'); return false; \"  HREF=\"javascript: void fPopWindow('" + SubMenuUrlAry[p][d] + "','help');\" ";
			} else if (SubMenuOptAry[p][d] == "1") {
				SubMenuAStuff=" TARGET=\"" + RICOLAHF_SubMenuTargetAry[p][d] + "\" class=\"HF_MenuOptionLink\" onMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "'); return false; \" onmouseout=\"return false;\" HREF=\"" + SubMenuUrlAry[p][d] + "\" ";
			} else {
				if (RICOLAHeader_useSSMenuOptions) {
					usingSSMenu = true;
					SubMenuAStuff=" CLASS=\"HF_MenuOptionLink HF_MenuOptionLink_Arrow\" onMouseOut=\"RICOLAHF_ShowSecondTierMenu(false, " + p + ", " + d + ");\" onMouseOver=\"RICOLAHF_ShowSecondTierMenu(true, " + p + ", " + d + ");\" HREF=\"" + SubMenuUrlAry[p][d] + "\" ";
				} else { // There is no 2nd-Teir Menu Options defined so just making it a normal link to prevent error.
					SubMenuAStuff=" TARGET=\"" + RICOLAHF_SubMenuTargetAry[p][d] + "\" CLASS=\"HF_MenuOptionLink\" onMouseOver=\"AppDropshowlayer('SubMenuOptionLay" + p + "');\" HREF=\"" + SubMenuUrlAry[p][d] + "\" ";
				}
			}
//			writeOutString += "<tr><td style=\"white-space: nowrap;\">";

			writeOutString[writeOutString.length] = "<a " + SubMenuAStuff;
			if (SubMenuTTAry[p][d] != "-1856") {
				writeOutString[writeOutString.length] = " TITLE=\"" + SubMenuTTAry[p][d] + "\" ";
			}
			if (usingSSMenu) {
				writeOutString[writeOutString.length] = " id='RICOLAHF_SubMenuOptionArrow_" + p + "_" + d + "' "
			}
			writeOutString[writeOutString.length] = ">" + SubMenuNameAry[p][d];
			if (usingSSMenu) {
				writeOutString[writeOutString.length] = "&nbsp;<img src='/graphics/apps/ricola1yellow/menuoption-arrow-right.gif' width='7' height='9' border='0' />";
			}
			writeOutString[writeOutString.length] = "</a>";
//			writeOutString += "</td><td>";
/*
			if (usingSSMenu) {
				writeOutString += "<a onMouseOut=\"RICOLAHF_ShowSecondTierMenu(false, " + p + ", " + d + ");\" onMouseOver=\"RICOLAHF_ShowSecondTierMenu(true, " + p + ", " + d + ");\"><img src=\"/graphics/apps/ricola1yellow/menu-arrow.gif\" width=\"7\" height=\"9\" border=\"0\" id=\"RICOLAHF_SubMenuOptionArrow_" + p + "_" + d + "\">&nbsp;</a>\n";
			} else {
				writeOutString += "<img src=\"/graphics/space.gif\" width=\"7\" height=\"9\" border=\"0\">\n";
			}
*/
//			writeOutString += "</td></tr>\n";
		}
	}
//	writeOutString += "</table>";
	document.getElementById("SubMenuOptionLay" + p).innerHTML = writeOutString.join("");
	return true;
}

/* *********************************************************************************************************************** */

function RICOLAHeader_RepaintSubMenuOptions() {		// Funciton that re-writes out the Sub Menu Options.
	for (var pq=0; pq<SubMenuUsedAry.length; pq++) {
		p=SubMenuUsedAry[pq];
		RICOLAHeader_WriteSubMenuOptionsLinks(p);
	}
}

/* *********************************************************************************************************************** */

function RICOLAHeader_clearMenuOptionsArray() {		// Function that clears the current Sub Menu Options array
	SubMenuUsedAry=new Array();
	SubMenuNameAry=new Array();
	SubMenuUrlAry=new Array();
	SubMenuOptAry=new Array();
	SubMenuTTAry=new Array();
	RICOLAHF_SubMenuTargetAry=new Array();
}

/* *********************************************************************************************************************** */

function MOAppDropshowlayer(lay,MOlay) {		// Function that just shows the Sub Menu Option Dropdown
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;

	if (ie4) {	// For IE only
//		document.all[lay].style.posLeft=document.all[MOlay].offsetLeft + document.all[MOlay].parentElement.offsetLeft;
	}
	AppDropshowlayer(lay);
}

/* *********************************************************************************************************************** */

function MenuOptions(inOptName, inOptURL, inOptType, inToolTip, inPageYouAreOn) {	// Sets the 1st level menu options array
	if ((inOptURL == "#") && (inOptType.toString() == "1")) {
		return true;
	}
	var currOpt = MenuNameAry.length;
	inOptName = inOptName.replace(/<[^>]+>/g, "");
	MenuNameAry[currOpt] = inOptName;
	MenuUrlAry[currOpt] = inOptURL;
	MenuOptAry[currOpt] = inOptType;
	if (RICOLAHF_isPortal()) {
		RICOLAHF_MenuTargetAry[currOpt] = "_self";
	} else {
		RICOLAHF_MenuTargetAry[currOpt] = "_top";
	}
	MenuToolTipAry[currOpt] = "1856";
	if (arguments.length > 3) {   // Has ToolTip or Target
		inToolTip = inToolTip.toString();
		if (inToolTip.search(/^target\:\s*(_self|_top|_parent|_blank)\s*$/i) != -1) {	// is a target
			RICOLAHF_MenuTargetAry[currOpt] = inToolTip.toString().replace(/^target\:\s*(_self|_top|_parent|_blank)\s*$/i, "$1").toLowerCase();
		} else {
			inToolTip = inToolTip.replace(/^\s*/, "").replace(/\s*$/, "");
			if (inToolTip != "") {
				MenuToolTipAry[currOpt]=inToolTip;
			}
		}
	}
	if (arguments.length > 4) {  // This is the var passed of the file that user is on, so it may be disabled in the menuoptions
		var currPathname=new String(window.location.pathname);
		var currPathAry=currPathname.split("/");
		var currFilename=new String(currPathAry[(currPathAry.length - 1)]);
		if (currFilename.indexOf(inPageYouAreOn) != -1) {
			MenuOptAry[currOpt]="0";
		}
	}
}

/* *********************************************************************************************************************** */

function SubMenuOptions(inRelatedMOptionS, inSubMOName, inSubMOURL, inMOptType, inToolTip, inPageYouAreOn) {
	// Stores the 2nd level of menu options
	if (arguments.length < 3) {
		alert("There are not enough parameters passed to the SubMenuOptions Function.  Please pass at least three options.  For more details, please check out documentation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplate/");
		return false;
	}
	RICOLAHeader_useSubMenuOptions = true;
	var inRelatedMOption=parseInt(inRelatedMOptionS) - 1;
	if (!SubMenuNameAry[inRelatedMOption]) {
		SubMenuNameAry[inRelatedMOption]=new Array();
		SubMenuUrlAry[inRelatedMOption]=new Array();
		SubMenuOptAry[inRelatedMOption]=new Array();
		SubMenuTTAry[inRelatedMOption]=new Array();
		RICOLAHF_SubMenuTargetAry[inRelatedMOption]=new Array();
		SubMenuUsedAry[SubMenuUsedAry.length]=inRelatedMOption;
	}
	var currOpt = SubMenuNameAry[inRelatedMOption].length;

	SubMenuNameAry[inRelatedMOption][currOpt]=inSubMOName;
	SubMenuUrlAry[inRelatedMOption][currOpt]=inSubMOURL;
	SubMenuOptAry[inRelatedMOption][currOpt]=inMOptType;
	SubMenuTTAry[inRelatedMOption][currOpt]="-1856";
	if (RICOLAHF_isPortal()) {
		RICOLAHF_SubMenuTargetAry[inRelatedMOption][currOpt] = "_self";
	} else {
		RICOLAHF_SubMenuTargetAry[inRelatedMOption][currOpt] = "_top";
	}
	if (arguments.length > 4) {
		inToolTip = inToolTip.toString();
		var ddS= inToolTip.search(/^target\:\s*(\S+)\s*$/i);
		if (inToolTip.toString().search(/^target\:\s*(_self|_top|_parent|_blank)\s*$/i) != -1) {	// is a target
			RICOLAHF_SubMenuTargetAry[inRelatedMOption][currOpt] = inToolTip.replace(/^target\:\s*(_self|_top|_parent|_blank)\s*$/i, "$1").toLowerCase();
		} else {
			inToolTip = inToolTip.replace(/^\s*/, "").replace(/\s*$/, "");
			if (inToolTip != "") {
				SubMenuTTAry[inRelatedMOption][currOpt]=inToolTip;
			}
		}
	}
	if (arguments.length > 5) {			// This is the var passed of the file that user is on, so it may be disabled in the menuoptions
		var currPathname=new String(window.location.pathname);
		var currPathAry=currPathname.split("/");
		var currFilename=new String(currPathAry[(currPathAry.length - 1)]);
		if (currFilename.indexOf(inPageYouAreOn) != -1) {
			SubMenuOptAry[inRelatedMOption][currOpt]="0";
		}
	}
}

/* *********************************************************************************************************************** */

function SubSubMenuOptions(inRelatedMenuOption, inRelatedSubMenuOption, inSubSubMenuOptionName, inSubSubMenuOptionURL, inSubSubMenuOptionType) {		// Stores the 3rd level of menu options.
	var extAry = new Array("st", "nd", "rd", "th");
	RICOLAHF_SubSubMenuOptions_FuncCall++;
	if (arguments.length < 5) {
		alert("RICOLA Header/Footer Error #0003: Not enough parameters sent to the \"SubSubMenuOptions\" function.\nThis function requires 5 parameters while only " + arguments.length + " were passed in.\n\nThe error occurred on the " + RICOLAHF_SubSubMenuOptions_FuncCall + ((RICOLAHF_SubSubMenuOptions_FuncCall > 4)? extAry[3] : extAry[(RICOLAHF_SubSubMenuOptions_FuncCall - 1)]) + " call to the \"SubSubMenuOptions\" function.\n\nFor more information, visit the documentation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplates/");
		return false;
	}
	var inRMO = parseInt(inRelatedMenuOption, 10);
	var inRSMO = parseInt(inRelatedSubMenuOption, 10);
	if (isNaN(inRMO) || isNaN(inRSMO)) {
		alert("RICOLA Header/Footer Error #0004: Related MenuOption or SubMenuOption was not a number.\nThe \"SubSubMenuOptions\" function requires that the first two parameters (the Related Menu Option Number and the Related Sub-Menu Option Number) must be integers.\n\nThe error occurred on the " + RICOLAHF_SubSubMenuOptions_FuncCall + ((RICOLAHF_SubSubMenuOptions_FuncCall > 4)? extAry[3] : extAry[(RICOLAHF_SubSubMenuOptions_FuncCall - 1)]) + " call to the \"SubSubMenuOptions\" function.\n\nFor more information, visit the documentation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplates/");
		return false;
	}
	inRMO--;
	inRSMO--;
	if ((MenuOptAry.length < inRMO)  || (MenuOptAry[inRMO] != 3)) {
		alert("RICOLA Header/Footer Error #0005: No Menu Option Defined for the 2nd-Tier Menu Option call.\nThe " + inRelatedMenuOption + ((inRMO > 3)? extAry[3] : extAry[inRMO]) + " MenuOption call did not have submenu options defined for it or did not exist (i.e. the \"MenuOptions\" function call did not have \"3\" passed into the third parameter).\n\nThe error occurred on the " + RICOLAHF_SubSubMenuOptions_FuncCall + ((RICOLAHF_SubSubMenuOptions_FuncCall > 4)? extAry[3] : extAry[(RICOLAHF_SubSubMenuOptions_FuncCall - 1)]) + " call to the \"SubSubMenuOptions\" function.\n\nFor more information, visit the documentation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplates/");
		return false;
	}
	if ((SubMenuOptAry[inRMO].length < inRSMO)  || (SubMenuOptAry[inRMO][inRSMO] != 3) || (!RICOLAHeader_useSubMenuOptions)) {
		alert("RICOLA Header/Footer Error #0006: No SubMenu Defined for the 2nd-Tier Menu Option call.\nThe " + inRelatedSubMenuOption + ((inRSMO > 3)? extAry[3] : extAry[inRSMO]) + " SubMenuOption call did not have 2nd-Tier options defined for it or did not exist (i.e. the \"SubMenuOptions\" function call did not have \"3\" passed into the third parameter).\n\nThe error occurred on the " + RICOLAHF_SubSubMenuOptions_FuncCall + ((RICOLAHF_SubSubMenuOptions_FuncCall > 4)? extAry[3] : extAry[(RICOLAHF_SubSubMenuOptions_FuncCall - 1)]) + " call to the \"SubSubMenuOptions\" function.\n\nFor more information, visit the documentation at http://home.www.uprr.com/emp/it/hf/ricola/apptemplates/");
		return false;
	}
	RICOLAHeader_useSSMenuOptions = true;
	var tmpCount = inRMO + "_" + inRSMO;
	if (!RICOLAHeader_SSMenuNameAry[tmpCount]) {
		RICOLAHeader_SSMenuNameAry[tmpCount]=new Array();
		RICOLAHeader_SSMenuUrlAry[tmpCount]=new Array();
		RICOLAHeader_SSMenuOptAry[tmpCount]=new Array();
		RICOLAHeader_SSMenuTTAry[tmpCount]=new Array();
		RICOLAHeader_SSTargetAry[tmpCount]=new Array();
		RICOLAHeader_SSMenuUsedAry[RICOLAHeader_SSMenuUsedAry.length]=tmpCount;
	}
	var currOpt = RICOLAHeader_SSMenuNameAry[tmpCount].length;

	RICOLAHeader_SSMenuNameAry[tmpCount][currOpt]=inSubSubMenuOptionName;
	RICOLAHeader_SSMenuUrlAry[tmpCount][currOpt]=inSubSubMenuOptionURL;
	RICOLAHeader_SSMenuOptAry[tmpCount][currOpt]=inSubSubMenuOptionType;
	RICOLAHeader_SSMenuTTAry[tmpCount][currOpt] = "-1856";
	RICOLAHeader_SSTargetAry[tmpCount][currOpt] = "_top";

	if (arguments.length > 5) {
		for (var i=5; i < arguments.length; i++) {
			if (arguments[i].toString().search(/^\s*Tool\s*Tip\s*:\s*.+\s*$/i) != -1) {	// ToolTip
				RICOLAHeader_SSMenuTTAry[tmpCount][currOpt] = arguments[i].toString().replace(/^\s*Tool\s*Tip\s*:\s*(.+)\s*$/i, "$1");
			} else if (arguments[i].toString().search(/^\s*Target\s*:\s*.+\s*$/i) != -1) {	// Target
				RICOLAHeader_SSMenuTTAry[tmpCount][currOpt] = arguments[i].toString().replace(/^\s*Target\s*:\s*(.+)\s*$/i, "$1");
			} else if (arguments[i].toString().search(/^\s*Disable\s*Page\s*:\s*.+\s*$/i) != -1) {	// Disable if it is the page you are on
				var currentLocation = new String(window.location);
				var testPage = arguments[i].toString().replace(/^\s*Disable\s*Page\s*:\s*(.+)\s*$/i, "$1");
				if (currentLocation.indexOf(testPage) != -1) {
					RICOLAHeader_SSMenuOptAry[tmpCount][currOpt] = 0;
				}
			}
		}
	}

	return true;
}

/* *********************************************************************************************************************** */

function AppName(DaAppName,DaAppURL) {	// Writes out the Top Black Bar
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	if (arguments.length > 0) {
		DaAppName = DaAppName.replace(/^(.*)\<BR>.*$/i, "$1");		// if there is a break, remove anything after it
		DaAppName = DaAppName.replace(/\<[^>]*\>/g, "");		// Removes any extra tags
		DaAppName = DaAppName.replace(/\&nbsp;?/gi, " ");		// Removes any &nbsp;
		DaAppName = DaAppName.replace(/^\s*/, "").replace(/\s*$/, ""); 	// Remove beginning and trailing spaces
	}
	var origination_URL = location.href;
	var LogoURLstr = (UPRR_SITE_IS_EXTERNAL) ? "/uprr/index.shtml" : (RICOLAHF_URLPrefix + "/emp/index.shtml");

	if ((RICOLAHF_PortalView) || (RICOLAHF_NoHFShow)) {
		document.write("<div class='NoHeader_TopLine'><a href=\"" + DaAppURL + "\" class='AppName'>" + DaAppName + "</a>");
		if (UsePageTitle) {
			document.write("<span class='PageTitle'> - " + DaPageTitle + "</span>");
		}
		document.writeln("</div>");
	} else {
		if (ie4 || ns6) {
			// This section writes out the printer view of the appliction header/footer [START]
			var prtdate=new Date();
			document.write("<DIV CLASS='ApplicationHeaderDivStylePrint'>");
			document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0'><TR><TD VALIGN='top'>");
			document.write("<IMG SRC='/graphics/apps/upshprint.gif' BORDER='0' WIDTH='80' HEIGHT='64' /></TD><TD WIDTH='100'>&nbsp;</TD><TD ALIGN='CENTER'>");
			document.write("<SPAN CLASS=\"AppPrintTitle\">" + document.title + "</SPAN><BR><SPAN CLASS=\"AppPrintPageTitle\">" + DaAppName);
			if (UsePageTitle) {
				document.write(" - " + DaPageTitle);
			}
			document.write( "</SPAN><BR><SPAN CLASS=\"txtsv\">" + window.location.protocol + "//" + window.location.host + window.location.pathname + "<BR>");

			if (RICOLAHeader_TestForServerDateTime()) {
				document.write("Page Received From Server On: " + RICOLAHF_serverTimeDate );
			} else {
				document.write("Page Received From Server On: " + prtdate + " (reported by users Machine)");
			}
			document.write("</TD></TR></TABLE></DIV>");
			// This section writes out the printer view of the appliction header/footer [END]
		}
		document.write("<DIV CLASS='ApplicationHeaderDivStyle' ID='ApplicationHeaderDiv'>");
		document.write("<DIV ID='topLogoLay'><A HREF='" + LogoURLstr + "' TARGET='_top'>&nbsp;</A></DIV>");
		document.write("<TABLE BORDER=\"0\" BORDERCOLOR=\"BLUE\" CELLPADDING=\"0\" CELLSPACING=\"0\" WIDTH=\"100%\" CLASS=\"AppHeader\">");
		document.write("<TR CLASS=\"AppHeaderTopRow\">");
		document.write("	<TD WIDTH=\"8\"><A NAME=\"top\">&nbsp;</A></TD>");
		document.write("	<TD WIDTH=\"155\" HEIGHT=\"60\" VALIGN=\"middle\" CLASS=\"header\"><A HREF=\"" + LogoURLstr + "\" TARGET=\"_top\">");

		document.write('<img src="/graphics/apps/ricola1yellow/up_shield.gif" style="margin-top: 9px;" border="0" alt="Return to the Union Pacific Homepage" />');

//		document.write("<IMG SRC=\"/graphics/employees/uplogo_main_w.gif\" WIDTH=\"153\" HEIGHT=\"45\" BORDER=\"0\" ALIGN=\"LEFT\" ALT=\"Return to the Union Pacific Homepage\" onMouseOver=\"this.src='/graphics/employees/uplogo_main_y.gif';\" onMouseOut=\"this.src='/graphics/employees/uplogo_main_n.gif';\">");

		document.write("</A></TD>");
		document.write("	<TD CLASS=\"header\" HEIGHT=\"60\" ALIGN=\"center\" NOWRAP>");
		document.write("<DIV ALIGN=\"center\"><A HREF=\"" + DaAppURL + "\" CLASS=\"AppNameOff\" TARGET=\"_top\">" + DaAppName + "</A>");
		if (UsePageTitle) {
			document.write("<BR><A CLASS=\"PageTitle\">" + DaPageTitle + "</A>");
		}
		if (ShowServer) {
			document.write("<BR><A CLASS=\"WhatServerOnDiv\">" + WhatServerOn + "</A>");
		}
		document.write("</DIV>");
		document.write("</TD>");
		document.write("<TD CLASS=\"txt\" WIDTH=\"122\" HEIGHT=\"60\" VALIGN=\"TOP\">&nbsp;");
		if (secureSite && showLetUsHelpYou) {
			document.write("<A HREF=\"/my/icc/secure/CallBack.jas#" + origination_URL + "\" TARGET=\"_blank\"><IMG SRC=\"/graphics/apps/letushelp_n.gif\" WIDTH=\"120\" HEIGHT=\"40\" BORDER=\"0\" ALIGN=\"TOP\" ALT=\"Allow Union Pacific Customer Service Representatives Assist You\" OnMouseOver=\"this.src='/graphics/apps/letushelp_y.gif';\" OnMouseOut=\"this.src='/graphics/apps/letushelp_n.gif';\"></A>");
		}
		document.write("</TD>	<TD WIDTH=\"8\">&nbsp;</TD>");
		document.write("</TR>");
	}
}

/* *********************************************************************************************************************** */

function Splash() {	// Writes out the Red Bar - Required Function
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	if ((RICOLAHF_PortalView) || (RICOLAHF_NoHFShow)) {
		document.writeln("<div class='NoHeader_BottomLine'>");
		RICOLAHF_WriteOutMenuOptions(false);
		document.writeln("</div>");
	} else {
		document.write("<TR CLASS=\"AppRow\">");
		document.write("	<TD WIDTH=\"8\" NOWRAP>&nbsp;</TD>");
		var MAX_AMOUNT_TO_EXPAND_ROOM = 8;	// This variable is used to show if there is not App Dropdown or App Suite, use that area for more menu options
		if (UPRR_SITE_IS_EXTERNAL) {
			if (!ShowDropDown && (MenuNameAry.length < MAX_AMOUNT_TO_EXPAND_ROOM)) {
				document.write("	<TD CLASS=\"header\" NOWRAP>&nbsp;&nbsp;</TD>");
				document.write("	<TD CLASS=\"header\" ALIGN=\"center\" NOWRAP>&nbsp;");
			} else if (ShowDropDown) {
				document.write("	<td nowrap class=\"header\">&nbsp;&nbsp;<a id=\"AppHeaderAppDropdownLay\" class='MenuOptionWithDropdown' href=\"/uprr/customers/\" OnMouseOver=\"AppDropshowlayer('AppRollover');\" OnMouseOut=\"AppDrophidelayer('AppRollover');\">Applications&nbsp;<img src='/graphics/apps/ricola1yellow/menuoption-arrow-down.gif' width='9' height='7' border='0' /></a></td>");
				document.write("	<TD CLASS=\"header\" ALIGN=\"center\" NOWRAP>&nbsp;");
			} else {
				document.write("	<TD CLASS=\"header\" ALIGN=\"center\" COLSPAN=\"3\" NOWRAP>&nbsp;");
			}
			if (showApplicationSuite) {	
				MenuOptions(ApplicationsSuiteTitle, "#", "3");
				for (var i=0; i < ApplicationsSuiteNameAry.length; i++) {
					SubMenuOptions(MenuNameAry.length, ApplicationsSuiteNameAry[i], ApplicationsSuiteURLAry[i],"1");
				}
			}
			RICOLAHF_WriteOutMenuOptions(true);

			document.write("&nbsp;</TD>");
//			if (showApplicationSuite) {
//				document.write("	<TD NOWRAP CLASS=\"header\" ALIGN=\"RIGHT\">&nbsp;&nbsp;&nbsp;&nbsp;<SPAN ID=\"appsuitedropdownMain\" style=\"position: relative;\"><A CLASS=\"MenuOptionOff\" OnMouseOver=\"this.className='MenuOptionOn'; AppDropshowlayer('appsuitedropdownLay');\" OnMouseOut=\"this.className='MenuOptionOff'; AppDrophidelayer('appsuitedropdownLay');\" HREF=\"#\">" + ApplicationsSuiteTitle + "&nbsp;<IMG SRC=\"/graphics/apps/ricola1yellow/menuoption-arrow-down.gif\" WIDTH=\"9\" HEIGHT=\"7\" BORDER=\"0\" ID=\"appsuitedropdownImg\" NAME=\"appsuitedropdownImg\"></A></SPAN></TD>");
//			} else {
				if (MenuNameAry.length > MAX_AMOUNT_TO_EXPAND_ROOM) {
					document.write("	<TD NOWRAP CLASS=\"header\"><IMG SRC=\"/graphics/space.gif\" HEIGHT=\"20\" BORDER=\"0\" WIDTH=\"120\"></TD>");
				} else {
					var holdstrA=new String("");
					if (!ns4) {
						 holdstrA=" onMouseOver=\"this.src='/graphics/apps/whats_new2_y.gif'\" onMouseOut=\"this.src='/graphics/apps/whats_new2_n.gif'\" ";
					}
					document.write("	<TD NOWRAP CLASS=\"header\"><A HREF=\"/uprr/info/whatsnew.shtml\" TARGET=\"_top\" class='MenuOption HF_whatsNew'>");
	//				document.write("<IMG SRC=\"/graphics/apps/whats_new2_n.gif\" HEIGHT=\"20\" BORDER=\"0\" WIDTH=\"120\" " + holdstrA + ">");
					document.write("What's New");
					document.write("</A></TD>");
				}
//			}
		} else {
			if (MenuNameAry.length < MAX_AMOUNT_TO_EXPAND_ROOM) {
				document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" NOWRAP>&nbsp;&nbsp;</TD>");
				document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" ALIGN=\"center\" NOWRAP>&nbsp;");
			} else if (ShowDropDown) {
				if (!ie4) {
					document.write("	<TD HEIGHT=\"30\" NOWRAP CLASS=\"header\">&nbsp;&nbsp;<A HREF=\"/uprr/customers/\"  TARGET=\"_top\" CLASS=\"AppRow\" OnMouseOver=\"this.className='MenuOptionOn';AppDropshowlayer('AppRollover');\" OnMouseOut=\"this.className='MenuOptionOff';AppDrophidelayer('AppRollover');\">Applications&nbsp;<IMG SRC=\"/graphics/apps/ricola1yellow/menuoption-arrow-down-off.gif\" NAME=\"AppHeaderAppDropdownImg\" ID=\"AppHeaderAppDropdownImg\" WIDTH=\"9\" HEIGHT=\"7\" BORDER=\"0\"></A></TD>");
				} else {
					document.write("	<TD HEIGHT=\"30\" NOWRAP CLASS=\"header\">&nbsp;&nbsp;<SPAN ID=\"AppHeaderAppDropdownLay\"><A HREF=\"#\" CLASS=\"AppRow\" OnMouseOver=\"this.className='MenuOptionOn';AppDropshowlayer('AppRollover');\" OnMouseOut=\"this.className='MenuOptionOff';AppDrophidelayer('AppRollover');\" TITLE=\"Jump To Other Union Pacific Applications\" >Applications&nbsp;<IMG SRC=\"/graphics/apps/ricola1yellow/menuoption-arrow-down-off.gif\" NAME=\"AppHeaderAppDropdownImg\" ID=\"AppHeaderAppDropdownImg\" WIDTH=\"9\" HEIGHT=\"7\" BORDER=\"0\"></A></SPAN></TD>");
				}
				document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" ALIGN=\"center\" NOWRAP>&nbsp;");
			} else {
				document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" ALIGN=\"center\" COLSPAN=\"3\" NOWRAP>&nbsp;");
			}
			if (showApplicationSuite) {	
				MenuOptions(ApplicationsSuiteTitle, "#", "3");
				for (var i=0; i < ApplicationsSuiteNameAry.length; i++) {
					SubMenuOptions(MenuNameAry.length, ApplicationsSuiteNameAry[i], ApplicationsSuiteURLAry[i],"1");
				}
			}

			
			RICOLAHF_WriteOutMenuOptions(true);

			document.write("&nbsp;</TD>");
//			if (showApplicationSuite) {
//				document.write("	<TD NOWRAP CLASS=\"header\" ALIGN=\"RIGHT\">&nbsp;&nbsp;&nbsp;&nbsp;<SPAN ID=\"appsuitedropdownMain\" style=\"position: relative;\"><A CLASS=\"MenuOptionOff\" OnMouseOver=\"this.className='MenuOptionOn'; AppDropshowlayer('appsuitedropdownLay');\" OnMouseOut=\"this.className='MenuOptionOff'; AppDrophidelayer('appsuitedropdownLay');\" HREF=\"#\">" + ApplicationsSuiteTitle + "&nbsp;<IMG SRC=\"/graphics/apps/ricola1yellow/menuoption-arrow-down-off.gif\" WIDTH=\"9\" HEIGHT=\"7\" BORDER=\"0\" ID=\"appsuitedropdownImg\" NAME=\"appsuitedropdownImg\"></A></SPAN></TD>");
//			} else {
				if (MenuNameAry.length < MAX_AMOUNT_TO_EXPAND_ROOM) {
					document.write("	<TD NOWRAP CLASS=\"header\"><IMG SRC=\"/graphics/space.gif\" HEIGHT=\"20\" BORDER=\"0\" WIDTH=\"120\"></TD>");
				}
//			}
		}
		document.write("<TD WIDTH=\"8\">&nbsp;</TD></TR>	");
		document.write("<TR BGCOLOR=\"White\">");
		document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" WIDTH=\"8\">&nbsp;</TD>");

		if (!RICOLAHeader_TestForUserID()) {	// Not Logged In or Can't find User ID
			document.write("	<TD CLASS=\"header\" COLSPAN=\"3\" VALIGN=\"middle\">");
			RICOLAHF_PrintOutReturnTos();
		} else {		// Show User ID
			document.write("	<TD CLASS=\"header\" COLSPAN=\"3\" VALIGN=\"top\">");
			document.write("<TABLE BORDER='0' CELLPADDING='0' CELLSPACING='0' WIDTH='100%'><TR><TD ALIGN=\"left\">");
			RICOLAHF_PrintOutReturnTos();
			document.write("</TD><TD ALIGN=\"right\" nowrap valign=\"top\">");

		//	document.write("	<TD CLASS=\"header\" HEIGHT=\"30\" VALIGN=\"top\" nowrap>");
			document.write("<SPAN CLASS=\"HeaderFooter_LoggedInAs\">Logged&nbsp;In&nbsp;As:</SPAN>&nbsp;&nbsp;&nbsp;<SPAN CLASS=\"HeaderFooter_UserId\">" + RICOLAHF_userID.toUpperCase() + "</SPAN>&nbsp;&nbsp;&nbsp;<A HREF=\"" + RICOLAHF_URLPrefix + "/admin/logout.cfm\" CLASS=\"HeaderFooter_Logout\">Log&nbsp;Out</A>&nbsp;&nbsp;");
			document.write("</TD></TR></TABLE>");
		}

		document.write("</TD><TD WIDTH=\"8\">&nbsp;</TD></TR>");
		document.write("</TABLE>");

		document.write("</DIV>");

		if (ShowDropDown) { RICOLAHeader_WriteAppDropdownList(); }  // Shows Application Dropdown on the left
//		if (showApplicationSuite) { RICOLAHeader_WriteAppSuite(); }	 //  Application Suite Dropdown Layer Definition
	}
	if (RICOLAHeader_useSubMenuOptions) { RICOLAHeader_WriteSubMenuOptions(); }	// For SubMenu Layers
	if (RICOLAHeader_useSSMenuOptions) { RICOLAHF_WriteSubSubMenuOptions(); } // For 2nd Tier Menu Options

	WritePleaseWaitContentBodyStart(); // Please Wait Header Section

// START: ****************************** CUSTOM MESSAGE FOR OUTAGE Sunday, October 31, 2004
//	RICOLAHeader_BlanketNotice("This application will be unavailable Sunday, Oct. 31, from 1:00 a.m. until 3:00 a.m. CT for scheduled maintenance. We apologize for the inconvenience.", "10/31/2004");

// END: ****************************** CUSTOM MESSAGE FOR OUTAGE Sunday, October 31, 2004

// NETSCAPE NOTICE
	if (ns4) {
		inlineDisplayMessage(1,"UP Supported Web Browsers","Effective May 5, 2003, Union Pacific Web sites will support only the following browser versions:<BR><BR>Netscape 6.2 and above / FireFox 1.0 and above<BR>Microsoft Internet Explorer 6.0 and above<BR><BR>If your office is not using one of the browser versions listed, you may experience difficulty accessing or using our applications. <br>Your browser is detected as <b>Netscape Navigator 4</b> <br>Union Pacific recommends conversion to one of the supported browsers.<BR><BR>Current versions may be downloaded free of charge from the following Web sites:<BR><BR><NOBR>Microsoft Internet Explorer:<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=\"http://www.microsoft.com/windows/ie/default.htm\">http://www.microsoft.com/windows/ie/default.htm</A><BR>Netscape:<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=\"http://channels.netscape.com/ns/browsers/default.jsp\">http://channels.netscape.com/ns/browsers/default.jsp</A></NOBR><BR><BR>If you have any concerns, please contact <A HREF=\"mailto:webmaster@up.com?subject=Netscape 4.x Support\">webmaster@up.com</A><BR><BR>Thank you,<BR>Union Pacific Web Support team");
	}

	var currAppName = new String(navigator.appName);
	var currUserAgent = new String(navigator.userAgent);
	if ((currAppName.indexOf("Microsoft Internet Explorer") != -1) && (currUserAgent.search(/MSIE [1-5]/) != -1)) {   // If IE & Not IE 6
		inlineDisplayMessage(1,"Web Browser Not Supported By UP","Union Pacific Web sites support only the following browser versions: Netscape 6.2 and above, FireFox 1.0 and above, and Microsoft Internet Explorer 6.0 and above.<BR><b>Your browser is being detected as Microsoft Internet Explorer v" + currUserAgent.replace(/^.*MSIE (\d\.?\d?\d?).*$/, '$1') + "</b> <br><br><a href=\"javascript: void RICOLAHF_showMoreInfo('MoreInfo');\" id=\"MoreInfoTxt\" style=\"color: #003399;\">Show More Information</a><div id=\"MoreInfoLay\" style=\"display: none;\"><br>Union Pacific recommends conversion to one of the supported browsers.<BR><BR>Current versions may be downloaded free of charge from the following Web sites:<BR><BR><NOBR>Microsoft Internet Explorer:<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=\"http://www.microsoft.com/windows/ie/downloads/critical/ie6sp1/default.mspx\">http://www.microsoft.com/windows/ie/downloads/critical/ie6sp1/default.mspx</A><BR>Netscape:<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF=\"http://channels.netscape.com/ns/browsers/default.jsp\">http://channels.netscape.com/ns/browsers/default.jsp</A></NOBR><BR><BR>If you have any concerns, please contact <A HREF=\"mailto:webmaster@up.com?subject=Below IE 6.0 Support\">webmaster@up.com</A><BR><BR>Thank you,<BR>Union Pacific Web Support team</div>");
	}

// DISPLAY MESSAGES

	if (UPRR_SITE_IS_EXTERNAL && msgindex) { RICOLAHeader_DisplayAppNotice(); } 	   // End if msgindex defined (if app has a notice file)
	if (useDisplayMessage) {
		inlineDisplayMessage(DisplayMessageType,DisplayMessageHeading,DisplayMessageMsg);
	}

	if (ie4 || ns6) {
		document.write("<DIV id='RICOLAHF_BodyContentArea'>	");			// Indents the content of the app 12 pixels (2 pixels if Lite Version or Print Version)
	}
}

/* *********************************************************************************************************************** */

function RICOLAHF_showMoreInfo(inName) {	// Used in displaying the message of whether the users browser is supported or not.  Because the message is so large on our current browsers supported, there is a "Show More Info" and "Hide More Info" section
	var ie4 = (document.all) ? true : false;
	var ns4 = (document.layers) ? true : false;
	var ns6 = (document.getElementById && !document.all) ? true : false;
	var inLay = new String(inName + "Lay");
	var inLink = new String(inName + "Txt");
	if (ie4) {
		var LayObj = document.all[inLay];
		var LinkObj = document.all[inLink];
	} else if (ns6) {
		var LayObj = document.getElementById([inLay]);
		var LinkObj = document.getElementById([inLink]);
	}
	if (LayObj.style.display.toString() == "none") {		// Show More Info
		LayObj.style.display = "inline";
		LinkObj.innerHTML = "Collapse More Information";
	} else {	// Hide More Info
		LayObj.style.display = "none";
		LinkObj.innerHTML = "Show More Information";
	}
}

/* *********************************************************************************************************************** */

function DisplayAppFooter() {		// Writes out Application Footer (Doesn't write it out if it is the Lite Version)
	if (ie4 || ns6) {
		document.write("</DIV>	");
	}
	WritePleaseWaitContentBodyEnd();
	if ((RICOLAHF_PortalView) || (RICOLAHF_NoHFShow)) { return true; }
	if (UPRR_SITE_IS_EXTERNAL) {
		document.write('<div class="ricAppFooter" id="ricAppFooter"><div class="ricAppFooterTop"><div class="ricAppFooterTopLink"><a href="#">Top of Page</a></div></div><div class="ricAppFooterCommon"><a href="http://www.up.com">Home</a>&nbsp;|&nbsp;<a href="http://www.uprr.com/info/whats_new">What\'s New</a>&nbsp;|&nbsp;<a href="/uprr/search/">Search</a>&nbsp;|&nbsp;<a href="http://www.uprr.com/aboutup/info/copyrght.shtml">Copyright</a>&nbsp;|&nbsp;<a href="http://www.uprr.com/aboutup/info/privacy.shtml">Privacy</a>&nbsp;|&nbsp;<a href="http://www.uprr.com/aboutup/info">Site Info</a>&nbsp;|&nbsp;<a href="http://www.uprr.com/info/feedback.shtml">Feedback</a></div></div>');
	} else {
		document.write('<div class="ricAppFooter" id="ricAppFooter"><div class="ricAppFooterTop"><div class="ricAppFooterTopLink"><a href="#">Top of Page</a></div></div><div class="ricAppFooterCommon"><a href="/emp/">Home</a>&nbsp;|&nbsp;<a href="/emp/search/">Search</a>&nbsp;|&nbsp;<a href="/cms_wetbs/secure/">Crew Boards</a>&nbsp;|&nbsp;<a href="/emp/newstuff">New Stuff</a>&nbsp;|&nbsp;<a href="/emp/hr/phonebook/">UP Phonebook</a>&nbsp;|&nbsp;<a href="/emp/news/uponline/">UP Online</a>&nbsp;|&nbsp;<a href="/helpinfo.shtml">Help/Info</a>&nbsp;|&nbsp;<a href="/feedback.shtml">Feedback</a></div></div>');
	}
}
