
<!--
	// Global variables
	var g_objLayerList = new Array();
	var g_iTimerID = Number( 0 );
	
	var g_strVisibleMenus = [ "", "", "", "" ];
	var g_iMenuLevels = 3;

    // determine if safari for workaround on dhtml menu/flash bug
    var bSafari = false;
    if (navigator.userAgent.indexOf("Safari") > -1) {
        bSafari = true;
    }


	// Browser Detection
	var bBrowser_isIE=(document.all)?1:0;
	var bBrowser_isNS4=(document.layers)?1:0;
	var bBrowser_isNS6=((document.getElementById)&&(navigator.appName=='Netscape'))?1:0;
	var bBrowser_isNS=(bBrowser_isNS4)?1:0;
	var bBrowser_isDHTML=(bBrowser_isIE||bBrowser_isNS4||bBrowser_isNS6)?1:0;
	var bBrowser_isMac=(navigator.userAgent.indexOf('Mac')!=-1)?1:0;
	var bBrowser_isIEMac=(bBrowser_isMac&&bBrowser_isIE)?1:0;
	var bBrowser_isIE4Mac=(bBrowser_isIEMac&&(navigator.appVersion.indexOf('4.',4)!=-1))?1:0;
	var bBrowser_isIE5Mac=(bBrowser_isIEMac&&(navigator.appVersion.indexOf('5.')!=-1))?1:0;	

	// This function builds the navigation menus
	// Uses: Global Arrays g_aMenus and g_aMenuItems
	function CreateMenus()
	{
		// Write out the opening divs
		document.write( '<div class="menu_outer_div"><center><div class="menu_inner_div">' );

		// Look through the list of menus and create them
		iMenuItem = Number( 1 );
		for ( iMenu=0; iMenu<g_aMenus.length; iMenu++ )
		{
			strMenu = String( g_aMenus[iMenu] );
			aMenu = strMenu.split( '|' );

			// Make sure this bBrowser_is a valid menu
			if ( aMenu.length == 4 )
			{
				// Build the HTML code for the menu
				strHTML = String("");

				strHTML += '<table width=120 border=0 cellspacing=0 cellpadding=1 bgcolor="#a6a6a6"><tr><td>';
				strHTML += '<table width=118 border=0 cellspacing=0 cellpadding=0 bgcolor="#ffffff" class="menu">';

				// Is this the first menu item ?
				bFirstItem = true;
				
				// Add the links for all the items
				for ( i=0; i<g_aMenuItems.length; i++ )
				{
					strMenuItem = String( g_aMenuItems[i] );
					aMenuItem = strMenuItem.split( '|' );
					
					// Make sure this bBrowser_is a valid item
					if ( aMenuItem.length == 7  &&  aMenuItem[ MENUITEM_MENUNAME ] == aMenu[ MENU_NAME ] )
					{
						// Add the dividor if needed
						if ( ! bFirstItem )
						{
							iHeight = ( ( aMenuItem[ MENUITEM_GROUP ] == "true" ) ? "2" : "1" );
						
							strHTML += '<tr>';
							strHTML += '<td width=10><img src="/global/images/spacer.gif" width=10 height=' + iHeight + ' border=0></td>';
							strHTML += '<td width=88 bgcolor="#bfbfbf"><img src="/global/images/spacer.gif" width=88 height=' + iHeight + ' border=0></td>';
							strHTML += '<td width=10 bgcolor="#bfbfbf"><img src="/global/images/spacer.gif" width=10 height=' + iHeight + ' border=0></td>';
							strHTML += '<td width=10><img src="/global/images/spacer.gif" width=10 height=' + iHeight + ' border=0></td>';
							strHTML += '</tr>';
						}
						else bFirstItem = false;			
					
						// How tall is this menu item
						iUnitsTall = Number( aMenuItem[ MENUITEM_UNITSTALL ] );
						iPixelsTall = String( Number( MENU_UNIT_HEIGHT[ iUnitsTall ] ) );

						// Is there a sub menu for this item?
						bSubMenu = aMenuItem[ MENUITEM_HASSUBMENU ] == "true";
						
						// If bSubMenu, but safari, mark as false to fix dhtml/flash bug
						if ( bSubMenu )
						{
						    if ( bSafari )
						        bSubMenu = false;
						}

						strHTML += '<tr>';
						strHTML += '<td width=10><img src="/global/images/spacer.gif" width=10 height=' + iPixelsTall + ' border=0></td>';
						strHTML += '<td width=' + ( bSubMenu ? '88' : '98' ) + ' colspan=' + ( bSubMenu ? '1' : '2' ) + ' valign=center>';
						strHTML += '<a';
						strHTML += ' href="' + aMenuItem[ MENUITEM_LINK ] + '"';
						strHTML += ' class="' + ( aMenuItem[ MENUITEM_HASSUBMENU ] == "true" ? 'nav_parent_link' : 'nav_link' ) + '"';
						
						if ( bSubMenu )
						{
							strHTML += ' onmouseover="MenuRoll(\'' + aMenuItem[ MENUITEM_SUBMENUNAME ] + '\',' + ( Number( aMenu[ MENU_LEVEL ] ) + 1 ) + ',true); Subroll(true);"';
							strHTML += ' onmouseout="Subroll(false);"';
						}
						else
						{
							strHTML += ' onmouseover="HideMenus( ' + ( Number( aMenu[ MENU_LEVEL ] ) + 1 ) + ')"; Subroll(true);"';
							strHTML += ' onmouseout="Subroll(false);"';
						}
						
						strHTML += '>'
						strHTML += aMenuItem[ MENUITEM_NAME ]
						strHTML += '</a></td>';
						
						// Menu Arrow
						if ( bSubMenu )
							strHTML += '<td width=10 valign=center><img src="/global/images/menus/arrow.gif" width=10 height=21></td>';
						
						strHTML += '<td width=10><img src="/global/images/spacer.gif" width=10 height=1></td>';
						strHTML += '</tr>';
					}
					iMenuItem++;
				}

				strHTML += '</table></td></tr></table>' + '<p>';
				
				CreateMenu( aMenu[ MENU_NAME ], strHTML, (Number(aMenu[ MENU_LEFT ])-(bWidePage?95:0)), aMenu[ MENU_TOP ] );
			}
		}
		document.write( '</center></div></div>' );
	}

	
	// Creates an individual menu
	function CreateMenu( strName, strHTML, iX, iY )
	{
		z = g_objLayerList.length;
		g_objLayerList[ z ] = strName;

		document.write('<div id="' + strName + '" style="position:absolute; left:' + iX + 'px; top:' + iY + 'px; width:120px; height:auto; visibility:hidden; z-index:' + (z+1000) + ';">');
		document.write( strHTML );
		document.write('</div>');
	}


	// Makes a menu visible
	function ShowMenu( strMenuName, iLevel )
	{
		if ( bLoaded == true )
		{
			// If we're showing a level 1 menu, then hide any flash pieces
			HideFlash();
		
			// If this menu is already visible, then we're done
			if ( g_strVisibleMenus[ iLevel ] == strMenuName )
			{
				// Do nothing
			}
			else
			{
				// Hide the previous menu, if any
				for ( i=iLevel; i<=g_iMenuLevels; i++ )
				{
					if ( g_strVisibleMenus[ i ] != "" )
					{
						DocumentObject( g_strVisibleMenus[ i ], true ).visibility = "hidden";						
						g_strVisibleMenus[ i ] = "";
					}
				}
				
				// Show the menu
				if ( strMenuName != "" )
				{
					DocumentObject( strMenuName, true ).visibility = "visible";
				}
				
				// Remember that this menu is visible
				g_strVisibleMenus[ iLevel ] = strMenuName;
			}
		}
	}

	
	// This function bBrowser_is called when user rolls over a menu item, to make sure the menu doesn't hide
	function Subroll( bOn )
	{
		clearTimeout( g_iTimerID );

		if ( ! bOn )
		{
			g_iTimerID = setTimeout( 'HideMenus( 1 );', 1500 );
		}
	}


	// This function is called when user rolls over a menu item, to make sure the menu doesn't hide
	function MenuRoll( strMenuName, iLevel, bOn )
	{
		if ( bLoaded == true )
		{
			clearTimeout( g_iTimerID );

			if ( bOn )
			{
				ShowMenu( strMenuName, iLevel );
			}
			else
			{
				g_iTimerID = setTimeout( 'HideMenus( 1 );', 1500 );
			}
		}
	}

	// Hides any visible menus
	function HideMenus( iLevel )
	{
		if ( bLoaded == true )
		{
			clearTimeout( g_iTimerID );
			ShowMenu( '', iLevel );
		}
		
		if ( iLevel <= 1 )
		{
			ShowFlash();
		}
	}

	// Hides any flash pieces on the page
	function HideFlash( )
	{
/*
		if ( bLoaded == true )
		{
			var objFlashDiv = DocumentObject( "flash_div", true );
			if ( objFlashDiv )
			{
				objFlashDiv.display = "none";
			}
		}
*/
	}

	// Hides any flash pieces on the page
	function ShowFlash( )
	{
/*
		if ( bLoaded == true )
		{
			var objFlashDiv = DocumentObject( "flash_div", true );
			if ( objFlashDiv )
			{
				objFlashDiv.display = "block";
			}
		}
*/
	}

//-->