/***********************************************************************************
*	(c) Ger Versluis 2000 version 5.411 24 December 2001 (updated Jan 31st, 2003 by Dynamic Drive for Opera7)
*	For info write to menus@burmees.nl		          *
*	You may remove all comments for faster loading	          *		
***********************************************************************************/

	var NoOffFirstLineMenus=5;			// Number of first level items
	var LowBgColor='white';			// Background color when mouse is not over
	var LowSubBgColor='white';			// Background color when mouse is not over on subs
	var HighBgColor='F0F0F0';			// Background color when mouse is over
	var HighSubBgColor='F0F0F0';			// Background color when mouse is over on subs
	var FontLowColor='red';				// Font color when mouse is not over
	var FontSubLowColor='red';			// Font color subs when mouse is not over
	var FontHighColor='red';			// Font color when mouse is over
	var FontSubHighColor='red';			// Font color subs when mouse is over
	var BorderColor='white';			// Border color
	var BorderSubColor='black';			// Border color for subs
	var BorderWidth=1;				// Border width
	var BorderBtwnElmnts=1;			// Border between elements 1 or 0
	var FontFamily="arial,comic sans ms,technical"	// Font family menu items
	var FontSize=8;				// Font size menu items
	var FontBold=1;				// Bold menu items 1 or 0
	var FontItalic=0;				// Italic menu items 1 or 0
	var MenuTextCentered='left';			// Item text position 'left', 'center' or 'right'
	var MenuCentered='left';			// Menu horizontal position 'left', 'center' or 'right'
	var MenuVerticalCentered='top';		// Menu vertical position 'top', 'middle','bottom' or static
	var ChildOverlap=.2;				// horizontal overlap child/ parent
	var ChildVerticalOverlap=.2;			// vertical overlap child/ parent
	var StartTop=0;				// Menu offset x coordinate
	var StartLeft=0;				// Menu offset y coordinate
	var VerCorrect=0;				// Multiple frames y correction
	var HorCorrect=0;				// Multiple frames x correction
	var LeftPaddng=3;				// Left padding
	var TopPaddng=2;				// Top padding
	var FirstLineHorizontal=1;			// SET TO 1 FOR HORIZONTAL MENU, 0 FOR VERTICAL
	var MenuFramesVertical=1;			// Frames in cols or rows 1 or 0
	var DissapearDelay=1000;			// delay before menu folds in
	var TakeOverBgColor=1;			// Menu frame takes over background color subitem frame
	var FirstLineFrame='navig';			// Frame where first level appears
	var SecLineFrame='space';			// Frame where sub levels appear
	var DocTargetFrame='space';			// Frame where target documents appear
	var TargetLoc='MenuPos';				// span id for relative positioning
	var HideTop=0;				// Hide first level when loading new document 1 or 0
	var MenuWrap=1;				// enables/ disables menu wrap 1 or 0
	var RightToLeft=0;				// enables/ disables right to left unfold 1 or 0
	var UnfoldsOnClick=0;			// Level 1 unfolds onclick/ onmouseover
	var WebMasterCheck=0;			// menu tree checking on or off 1 or 0
	var ShowArrow=0;				// Uses arrow gifs when 1
	var KeepHilite=1;				// Keep selected path highligthed
	var Arrws=['tri.gif',5,10,'tridown.gif',10,5,'trileft.gif',5,10];	// Arrow source, width and height
	
	//
	// Fabrice variables
	//
	
	// set page location to web site root
	// IMPORTANT: make sure this is the correct Web Site Root and include dir
	//var strWebSiteRoot = "file:///D:/Websites/www.fabricetalbot.com/webroot/t2a/"
	var strWebSiteRoot = "http://www.t2acommunications.com/"
	//var strWebSiteRoot = "file:///C:/Documents%20and%20Settings/tmulvihill/My%20Documents/Administration/t2aCommunications/Website/t2a/"
	
	// relative path to web site root
	var strGo2SiteRoot = GetPath2WebSiteRoot(strWebSiteRoot);
	
	// Relative path to site sections from 
	var strPath2Company		=	strGo2SiteRoot + "company/";
	var strPath2Services		=	strGo2SiteRoot + "services/";
	var strPath2Clients		=	strGo2SiteRoot + "clients/";
	var strPath2Benefits		=	strGo2SiteRoot + "benefits/";
	

// Author: 	Fabrice Talbot
// Function:	GetPath2WebSiteRoot()
// Description: Goes all levels up through folders until it reaches the web site root
//		and returns the path calculated  
// Example:	GetPath2WebSiteRoot("http://www.google.com/search/results/index.html") returns "../../"
function GetPath2WebSiteRoot(iWebSiteRoot)
{
	var strResult		=	""
	var intRootLen		=	iWebSiteRoot.length
	var strPageLocation	=	document.location.toString();
	var strPageRoot		=	strPageLocation.substring(0, intRootLen);
	
	// if 	--> Page root = site root
	// else --> Invalid page root
	if (strPageRoot == iWebSiteRoot)
	{
		// calculate nb levels in relative page path
		var strPageRightPath 	= 	strPageLocation.substring(intRootLen, strPageLocation.length);
		var intNbLevelsUp 	=	strPageRightPath.split("/").length - 1;
		
		// build path to web site root
		for (var idx=0; idx<intNbLevelsUp; idx++)
		{
			strResult += "../";
		}		
	}
	else
	{
		alert("Unable to match page location root ('" + strPageRoot + "' with the web site root define in file 'config.js' ('" + iWebSiteRoot + "')");
	}
	//alert(strResult)
	return(strResult);
}

// set classname for a given HTML tag
function BgColor(tagID, className) {
	document.getElementById(tagID).className = className
	return;
}

// set classname for services HTML tags
function BgColor2(tagID, tagClass, serviceID, titleClass, rowClass) {
	//alert(document.getElementById("t1_" + "service" + serviceID).innerHTML)
	//alert(document.getElementById("t2_" + "service" + serviceID).innerHTML)
	document.getElementById(tagID).className = tagClass;
	document.getElementById("h_" + tagID).className = tagClass;
	document.getElementById("f_" + tagID).className = tagClass;
	document.getElementById("t1_service" + serviceID).className = titleClass;
	document.getElementById("t2_service" + serviceID).className = titleClass;
	document.getElementById("c_service" + serviceID).className = rowClass;
	return;
}		

function ShowImage(tagID, imgSrc) {
	document.getElementById(tagID).src = strGo2SiteRoot + "images/" + imgSrc;	
	//alert(document.getElementById(tagID).src)
	return;	
}	

function BeforeStart(){return}
function AfterBuild(){return}
function BeforeFirstOpen(){return}
function AfterCloseAll(){return}


// Menu tree
//	MenuX=new Array(Text to show, Link, background image (optional), number of sub elements, height, width);
//	For rollover images set "Text to show" to:  "rollover:Image1.jpg:Image2.jpg"

Menu1=new Array("COMPANY", strPath2Company + "index.html","",0,18,90);

Menu2=new Array("SERVICES", strPath2Services + "index.html","",4,18,90);
	Menu2_1=new Array("Technical Documentation", strPath2Services + "tech_doc.html","",0,20,185);
	Menu2_2=new Array("Single-source Documentation", strPath2Services + "singlesource_doc.html","",0,20,138);
	Menu2_3=new Array("Consulting and Training", strPath2Services + "consulting.html","",0,20,138);
	Menu2_4=new Array("Free Assessment", strPath2Services + "assessment.html","",0,20,138);

Menu3=new Array("CLIENTS", strPath2Clients + "index.html","",0,18,90);

Menu4=new Array("BENEFITS", strPath2Benefits + "index.html","",0,18,90);

Menu5=new Array("CONTACT", strGo2SiteRoot + "contact.html","",0,18,115);
