/*
leftNonDisclosure - non_disclosure.php
leftContact - contact.php
leftAutomotive - automotive.php
leftConsumerGoods - consumer_goods.php
leftHealthcare - healthcare.php
leftPharmaceutical - pharmaceutical.php
leftRecreationalVehicles - recreational_vehicles.php
leftTelecommunications - telecommunications.php
leftManagementEngineering management_engineering.php
leftClinicalEngineering clinical_engineering.php
leftIndustrialEneingeering industrial_engineering.php
leftSimulation simulation.php
leftProjectManagement project_management.php
leftCaseStudy01 - 01/default.php
leftCaseStudy02 - 02/default.php
leftCaseStudy03 - 03/default.php
leftCaseStudy04 - 04/default.php
leftCaseStudy05 - 05/default.php
leftCaseStudy06 - 06/default.php
*/




function leftLocationFunction () {
	//get the URL of the current page, convert it to a string and make the string lowercase	
	var location = window.location
	location = location.toString()
	location = location.toLowerCase()
	// alert(location)
	
	// define a new array to contain the pairs necessary to identify the current page and corresponding div
	leftNavItem = new Array();
	
	// page is a string containing the name of the page each section of the site is contained in, framed by slashes
	// menuLink is a string containing the unique id of the <a> tag that the menuCurrentLoc class  needs to be applied to
	leftNavItem[0] = new Object();
			leftNavItem[0].page = "default.php"; 
			leftNavItem[0].menuLink = "leftDefault";
	
    
	// initiate a for loop to cycle through the array of site directories
	for (var i=0; i < leftNavItem.length; i++) {
	
	// move through the array, checking if the .page element string is present in the URl of the current page  
	if 	(location.match(leftNavItem[i].page))  { 
		// change the class of the corresponding menu item if it matches the current page
	    document.getElementById(leftNavItem[i].menuLink).className="menuCurrentLoc";
		return;
	}
	
	}
	
}
