﻿// JavaScript Document
//
//
// Delta Annual Report Navigation Javascript
// (c) 2006 Savage Design Group, Inc.
// Questions? Chris MacGregor :: cmacgregor@savagedesign.com
//
//
var breadArr = new Array();
//
// Get the file name of the document calling these scripts
// and create an array of URLstring encoded vars.
var sp = document.URL.split('/');
var thisURL = sp[(sp.length-1)];
var stringArr = new Array();
if (thisURL.indexOf('?') != -1) {
	splitURL = thisURL.split('?');
	thisURL = splitURL[0];
	stringArr = splitURL[1].split('&');
	for (i = 0; i < stringArr.length; i ++) {
		stringArr[i] = stringArr[i].split('=');
	}
}
//
function makePopMenu(num) {
// function to build pop-up menus:
	vt = divArr[num];
	arr = navArr[num];
	for (i = 0; i<arr.length; i ++) {
		var divID = "<div class='popMenuItem' id='popUL'>";
		if ((i+1) == arr.length) {
			divID = "<div class='popMenuItem'>"	
		}
		if (thisURL != arr[i][1]) {
			vt += divID + '<a href="'+arr[i][1]+'">'+arr[i][0]+'</a></div>';
		} else {
			vt += divID+arr[i][0]+'</div>';
		}
	}
	vt += '</div>';
	document.write(vt);
	//window.alert(vt);
}
//
function fixBreak(str) {
	// some strings have BR tags in them. Take them out here.
	if (str.indexOf('<br />') != -1) {
			tempA = str.split('<br />');
			str = tempA.join(' ');
	}
	return str;
}
//


//
function breadCrumbs() {
	// builds breadcrumbs for the current page. uncomment last line to add them to the page.
	var bc = '<div class="breadcrumb"><a href="index.html">Home</a> :: ';
	for (i = 0; i < breadArr.length; i ++) {
		if ((i+1) < breadArr.length) {
			bc += '<a href="'+breadArr[i][1]+'">'+breadArr[i][0]+'</a> :: ';
		} else {
			bc += ''+breadArr[i][0]+'';
		}
	}
	bc += "</div>";
	//document.write(bc);
}
		
//
function modNavi() {
	// function used to control the 'fly dots' image at the top of the header nav.
	thisSec = thisURL.substr(0,2);
	MM_swapImage('nav'+thisSec,'','images/nav_'+thisSec+'_1.gif',1);
}
//

// construction arr for pop-ups
var divArr = new Array();
	// array used for constructing the side menus.
// divArr.push(' ');
// divArr.push("<div class=\"popMenu\" ID=\"popAB\" onMouseOver=\"MM_nbGroup('over','navAB','images/nav_AB_1.gif','','','','',1);showMenu('popAB')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");
// divArr.push("<div class=\"popMenu\" ID=\"popTE\" onMouseOver=\"MM_nbGroup('over','navTE','images/nav_TE_1.gif','','','','',1);showMenu('popTE')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");
// divArr.push("<div class=\"popMenu\" ID=\"popBE\" onMouseOver=\"MM_nbGroup('over','navBE','images/nav_BE_1.gif','','','','',1);showMenu('popBE')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");
// divArr.push("<div class=\"popMenu\" ID=\"popHS\" onMouseOver=\"MM_nbGroup('over','navHS','images/nav_HS_1.gif','','','','',1);showMenu('popHS')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");
// divArr.push("<div class=\"popMenu\" ID=\"popNE\" onMouseOver=\"MM_nbGroup('over','navNE','images/nav_NE_1.gif','','','','',1);showMenu('popNE')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");
// divArr.push("<div class=\"popMenu\" ID=\"popCO\" onMouseOver=\"MM_nbGroup('over','navCO','images/nav_CO_1.gif','','','','',1);showMenu('popCO')\" onMouseOut=\"hideMenu();MM_nbGroup('out')\">");




// Begin pop-up navigation.
// var sec31Arr = new Array();
// var navArr = new Array();
// var sec1Arr = new Array();
// 	sec1Arr.push([' ',' ']);
// 	sec1Arr.push(['About Us','index.html']);
// 	sec1Arr.push(['Technology','TE_overview.html']);
// 	sec1Arr.push(['Benefits','BE_overview.html']);
// 	sec1Arr.push(['HSE','HS_overview.html']);
// 	sec1Arr.push(['News & Events','NE_Home.html']);
// 	sec1Arr.push(['Contact Us','CO_contact_list.html']);
// 	navArr.push(sec1Arr);
// var sec2Arr = new Array();
// 	sec2Arr.push(['Home','index.html']);
// 	sec2Arr.push(['Overview','AB_overview.html']);
// 	sec2Arr.push(['Development History','AB_development_history.html']);
// 	sec2Arr.push(['Career Opportunities','AB_career_opportunities.html']);
// 	sec2Arr.push(['Vision, Mission & Values','AB_mission_values.html']);
// navArr.push(sec2Arr);
// var sec3Arr = new Array();
// 	sec3Arr.push(['Overview','TE_overview.html']);
// 	sec3Arr.push(['Automated Pressure Drilling','TE_APD_services.html',sec31Arr]);
// 	sec3Arr.push(['Managed Pressure Drilling','TE_mpd_system.html']);
// 	//sec3Arr.push(['Qualifications & Experience','TE_qualifications.html']);
// navArr.push(sec3Arr);
// var sec4Arr = new Array();
// 	sec4Arr.push(['Overview','BE_overview.html']);
// 	sec4Arr.push(['Applications','BE_applications.html']);
// 	sec4Arr.push(['Case Histories','BE_case_histories.html']);
// 	sec4Arr.push(['True Value Matrix','BE_value_matrix.html']);
// navArr.push(sec4Arr);
// var sec5Arr = new Array();
// 	sec5Arr.push(['Overview','HS_overview.html']);
// 	sec5Arr.push(['Policy Statement','HS_policy_statement.html']);
// 	sec5Arr.push(['Core Beliefs','HS_core_beliefs.html']);
// navArr.push(sec5Arr);
// var sec6Arr = new Array();
// 	sec6Arr.push(['News','NE_Home.html']);
// 	sec6Arr.push(['Press Releases','NE_press_releases.html']);
// 	sec6Arr.push(['Articles','NE_articles.html']);
// 	sec6Arr.push(['Industry Events','NE_Industry Events.html']);
// 	//sec6Arr.push(['Past Events','NE_past_events.html']);
// navArr.push(sec6Arr);
// var sec7Arr = new Array();
// 	sec7Arr.push(['Contact List','CO_contact_list.html']);
	//sec7Arr.push(['Information Request Form','CO_information_request.html']);
// navArr.push(sec7Arr);
//
sec31Arr.push(['Choke Manifold','TE_choke_manifold.html']);
sec31Arr.push(['Backpressure Pump','TE_backpressure.html']);
sec31Arr.push(['Control System','TE_control_system.html']);
sec31Arr.push(['Data Acquisition for Kick Detection','TE_data_acquisition.html']);