<!--


// removes ie and nav 6 annoying link boxes.
// and a seperate script in the preload
	function unblur() {
		this.blur();
	}

	function getLinksToBlur() {
		if (!document.getElementById) return
		links = document.getElementsByTagName("a");
		for(i=0; i<links.length; i++) {
			links[i].onfocus = unblur
		}
	}


// preloads
function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		nav_about_over = newImage("images/nav_about-over.gif");
		nav_practice_over = newImage("images/nav_practice-over.gif");
		nav_services_over = newImage("images/nav_services-over.gif");
		nav_partners_over = newImage("images/nav_partners-over.gif");
		nav_government_over = newImage("images/nav_government-over.gif");
		nav_customers_over = newImage("images/nav_customers-over.gif");
		nav_news_over = newImage("images/nav_news-over.gif");
		nav_careers_over = newImage("images/nav_careers-over.gif");
		nav_contact_over = newImage("images/nav_contact-over.gif");

// homepage nav shit
		voice_link_over = newImage("images/voice_link-over.gif");
		voice_text_over = newImage("images/voice_text.gif");
		voice_textin_over = newImage("images/voice_linkin-over.gif");
		data_link_over = newImage("images/data_link-over.gif");
		data_text_over = newImage("images/data_text.gif");
		data_textin_over = newImage("images/data_linkin-over.gif");
		network_link_over = newImage("images/network_link-over.gif");
		network_text_over = newImage("images/network_text.gif");
		network_textin_over = newImage("images/network_linkin-over.gif");
		security_link_over = newImage("images/security_link-over.gif");
		security_linkin_over = newImage("images/security_linkin-over.gif");

// SUB ABOUT
		sub_about_peop_over = newImage("images/sub_about_peop-over.gif");
		sub_about_app_over = newImage("images/sub_about_app-over.gif");
		sub_about_need_over = newImage("images/sub_about_need-over.gif");
		sub_about_avaya_over = newImage("images/sub_about_avaya-over.gif");
		sub_about_exec_over = newImage("images/sub_about_exec-over.gif");

// SUB PRACTICE AREAS
		sub_areas_con_over = newImage("images/sub_areas_con-over.gif");
		sub_areas_tele_over = newImage("images/sub_areas_tele-over.gif");
		sub_areas_net_over = newImage("images/sub_areas_net-over.gif");
		sub_areas_conv_over = newImage("images/sub_areas_conv-over.gif");
		sub_areas_mob_over = newImage("images/sub_areas_mob-over.gif");
		sub_areas_loss_over = newImage("images/sub_areas_loss-over.gif");

// SUB CUSTOMERS
		sub_customers_log_over = newImage("images/sub_customers_log-over.gif");
		sub_customers_case_over = newImage("images/sub_customers_case-over.gif");

// SUB NEWS
		sub_news_news_over = newImage("images/sub_news_news-over.gif");
		sub_news_press_over = newImage("images/sub_news_press-over.gif");
		sub_news_events_over = newImage("images/sub_news_events-over.gif");

// SUB GOVEDU
		sub_gov_contracts_over = newImage("images/sub_gov_contracts-over.gif");

// SUB PARTNERS
		sub_part_technology_over = newImage("images/sub_part_technology-over.gif");
		sub_part_security_over = newImage("images/sub_part_security-over.gif");

		preloadFlag = true;
		//// removes ie link boxes
		getLinksToBlur();
	}
}


// simple js pop up center....no thrills
var win= null;
function sidecar(mypage,myname,w,h,scroll){
var winl = (screen.width-w)/2;
var wint = (screen.height-h)/2;
settings='height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',toolbar=no,location=no,status=no,menubar=no,resizable=yes,dependent=no'
win=window.open(mypage,myname,settings)
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}

// print
function printpage() {
	window.print();  
}

// sub shit
Menu = {timer : null, current : null};
Menu.getStyle = function(name){
	if(document.getElementById) return document.getElementById(name).style;
	else if(document.all) return document.all[name].style;
	else if(document.layers) return document.layers[name];
}
Menu.show = function(name){
	if(this.timer) clearTimeout(this.timer);
	this.getStyle(name).visibility = "visible";
	this.current = name;
}
Menu.hide = function(){
	this.timer = setTimeout("Menu.doHide()",4000);
}
Menu.doHide = function(){
	if(this.current){
		this.getStyle(this.current).visibility = "hidden";
		this.current = null;
	}
}

// hides teh shit
function no_error()
{ return true; }
window.onerror=no_error;

/*
	If you use a DOCTYPE that puts Explorer 6 in standards compliant mode, some properties 
	of document.body are reassigned to document.documentElement. In Explorer 5 the 
	properties still belong to document.body. Checking if the documentElement exists is not 
	enough, since it exists in all W3C DOM compatible browsers, so we also have to see if 
	it has the property we are trying to access.
	For more info on this topic visit http://www.xs4all.nl/~ppk/js/doctypes.html
*/

var ScrollWin = {
	w3c : document.getElementById,
	iex : document.all,
	scrollLoop : false, 
	scrollInterval : null, // setInterval id
	currentBlock : null,   // object reference
	getWindowHeight : function(){
		if(this.iex) return (document.documentElement.clientHeight) ? document.documentElement.clientHeight : document.body.clientHeight;
		else return window.innerHeight;
	},
	getScrollLeft : function(){
		if(this.iex) return (document.documentElement.scrollLeft) ? document.documentElement.scrollLeft : document.body.scrollLeft;
		else return window.pageXOffset;
	},
	getScrollTop : function(){
		if(this.iex) return (document.documentElement.scrollTop) ? document.documentElement.scrollTop : document.body.scrollTop;
		else return window.pageYOffset;
	},
	getElementYpos : function(el){
		var y = 0;
		while(el.offsetParent){
			y += el.offsetTop
			el = el.offsetParent;
		}
		return y;
	},
	scroll : function(num){
		if(!this.w3c){
			location.href = "#"+this.anchorName+num;
			return;
		}
		if(this.scrollLoop){
			clearInterval(this.scrollInterval);
			this.scrollLoop = false;
			this.scrollInterval = null;
		}
		if(this.currentBlock != null) this.currentBlock.className = this.offClassName;
		this.currentBlock = document.getElementById(this.blockName+num);
		this.currentBlock.className = this.onClassName;
		var doc = document.getElementById(this.containerName);
		var documentHeight = this.getElementYpos(doc) + doc.offsetHeight;
		var windowHeight = this.getWindowHeight();
		var ypos = this.getElementYpos(this.currentBlock);
		if(ypos > documentHeight - windowHeight) ypos = documentHeight - windowHeight;
		this.scrollTo(0,ypos);
	},
	scrollTo : function(x,y){
		if(this.scrollLoop){
			var left = this.getScrollLeft();
			var top = this.getScrollTop();
			if(Math.abs(left-x) <= 1 && Math.abs(top-y) <= 1){
				window.scrollTo(x,y);
				clearInterval(this.scrollInterval);
				this.scrollLoop = false;
				this.scrollInterval = null;
			}else{
				window.scrollTo(left+(x-left)/2, top+(y-top)/2);
			}
		}else{
			this.scrollInterval = setInterval("ScrollWin.scrollTo("+x+","+y+")",100);
			this.scrollLoop = true;
		}
	}
};

// ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
/*
using the following line, IE/PC returns an incorrect number when getting the document height.
var document_height = document.all ? document.body.offsetHeight : window.document.height;
To fix this problem, a container div is wrapped around the content so the correct height 
can be determined.
*/

// Edit these variables

ScrollWin.containerName = "container"; // The id name of the div containing the content
ScrollWin.anchorName    = "anchor";    // The alpha portion of the anchor names
ScrollWin.blockName     = "block";     // The alpha portion of the content blocks
ScrollWin.onClassName   = "active";    // The CSS class name for the 'on' state
ScrollWin.offClassName  = "visited";   // The CSS class name for the 'off' state

// ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||


// form next values
function toUnicode(elmnt,content)
{
if (content.length==elmnt.maxLength)
	{
	next=elmnt.tabIndex
	if (next<document.forms[0].elements.length)
		{
		document.forms[0].elements[next].focus()
		}
	}
}

// -->
