// JavaScript Document
function MM_Nav4() {
NS4 = (document.layers) ? true : false;
if (NS4)
				document.write("<input type='submit' name='Submit' value='Search' alt='Search Mackenzie Gas Project Website'>");
			else
				document.write("<input border='0' name='submit' type='image' src='http://www.mackenziegasproject.com/indexImages/Search.gif' alt='Search Mackenzie Gas Project Website'>")
}
				

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);


function P7_autoLayers() { //v1.4 by PVII
 var g,b,k,f,args=P7_autoLayers.arguments;a=parseInt(args[0]);if(isNaN(a))a=0;
 if(!document.p7setc){p7c=new Array();document.p7setc=true;for(var u=0;u<10;u++){
 p7c[u]=new Array();}}for(k=0;k<p7c[a].length;k++){if((g=MM_findObj(p7c[a][k]))!=null){
 b=(document.layers)?g:g.style;b.visibility="hidden";}}for(k=1;k<args.length;k++){
 if((g=MM_findObj(args[k]))!=null){b=(document.layers)?g:g.style;b.visibility="visible";f=false;
 for(var j=0;j<p7c[a].length;j++){if(args[k]==p7c[a][j]) {f=true;}}
 if(!f){p7c[a][p7c[a].length++]=args[k];}}}
}


function MM_swapMyImage(){

var path=window.location.pathname;
//document.write(path);
splitPath=path.split("/");

switch(splitPath[1])
{
	case "whoWeAre": // folder name
   		document.whoWeAre.src="http://www.mackenziegas.ca/sharedImages/WhoWeAreRO.gif";  // image name of rollover
		break;
	case "theProject": // the project
   		document.theProject.src="http://www.mackenziegas.ca/sharedImages/ProjectRO.gif";
		break;
	case "opportunities": // Opportunites
   		document.opportunities.src="http://www.mackenziegas.ca/sharedImages/OpportunitiesRO.gif";
		break;
 	case "ourCommitment": // Our Commitment
   		document.ourCommitment.src="http://www.mackenziegas.ca/sharedImages/OurCommitmentRO.gif";
		break;
	case "whatsNew": // What's New?
   		document.whatsNew.src="http://www.mackenziegas.ca/indexImages/what_newRO.gif";
		break;
	case "contactUs": // Contact US
   		document.contactUs.src="http://www.mackenziegas.ca/indexImages/ContactUsRO.gif";
		break;
	case "moreInformation": // More Information
   		document.moreInformation.src="http://www.mackenziegas.ca/indexImages/Learn_MoreRO.gif";
		break;				
	case "links": // Links
   		document.Links.src="http://www.mackenziegas.ca/indexImages/LinksRO.gif";
		break;
	case "siteMap": // Site Map
   		document.siteMap.src="http://www.mackenziegas.ca/indexImages/SiteMapRO.gif";
		break;
	case "legalStatement": // this page probably doesn't have a rollover for Legal Statement
   		document.legalStatement.src="http://www.mackenziegas.ca/indexImages/legalStatementRO.gif";
		break;		
	case "industryDefinitions": // Industry Definitions
   		document.industryDefinitions.src="http://www.mackenziegas.ca/indexImages/DefinitionsRO.gif";
		break;
}

switch(splitPath[2])
{
   case "contractors": //Who we are - Contractors
 		document.Contractors.src="http://www.mackenziegas.ca/sharedImages/ContractorsRO.gif";
		break;
   case "overview": //The Project - Overview
 		document.overview.src="http://www.mackenziegas.ca/sharedImages/OverviewRO.gif";
		break;
   case "projectDescription": //The Project -  Project Description
   		document.projectDescription.src="http://www.mackenziegas.ca/sharedImages/projectDescriptionRO.gif";
		break;
   case "whyNow": //The Project -  Why Now?
   		document.whyNow.src="http://www.mackenziegas.ca/sharedImages/whyNowRO.gif";
		break;
    case "regulatoryProcess": //The Project - Regulatory Process
   		document.regulatoryProcess.src="http://www.mackenziegas.ca/sharedImages/regulatoryProcessRO.gif";
		break;
   case "constructionOperation": //The Project - Construction & Operation    <---------
   		document.constructionOperation.src="http://www.mackenziegas.ca/sharedImages/constructionOperationR.gif";
		break;
   case "safetyEnvironment": //Our Commitment - Safety and Environment
 		document.safetyEnvironment.src="http://www.mackenziegas.ca/sharedImages/safetyEnvironmentRO.gif";
		break;
   case "communityInvolvement": //Our Commitment - Community Involvement
 		document.communityInvolvement.src="http://www.mackenziegas.ca/sharedImages/communityInvolvementRO.gif";
		break;
   case "sharingInformation": //Our Commitment - Sharing Information
   		document.sharingInformation.src="http://www.mackenziegas.ca/sharedImages/sharingInformationRO.gif";
		break;
   case "landAccess": //Our Commitment - Land Access
   		document.landAccess.src="http://www.mackenziegas.ca/sharedImages/landAccesRO.gif";
		break;
    case "educationTraining": //Opportunities - Education & Training
   		document.educationTraining.src="http://www.mackenziegas.ca/sharedImages/educationTrainingRO.gif";
		break;
   case "businessOpportunities": //Opportunities - Business Opportunities
   		document.businessOpportunities.src="http://www.mackenziegas.ca/sharedImages/businessOpportunitiesR.gif";
		break;
   case "employment": //Opportunities - Employment
 		document.employment.src="http://www.mackenziegas.ca/sharedImages/employmentRO.gif";
		break;
   case "benefits": //Opportunities - Benefits
 		document.benefits.src="http://www.mackenziegas.ca/sharedImages/benefitsRO.gif";
		break;
   case "donations": //Opportunities - Donations
   		document.donations.src="http://www.mackenziegas.ca/sharedImages/donationsRO.gif";
		break;
   case "newsReleases": //What's New - News Releases
   		document.newsReleases.src="http://www.mackenziegas.ca/sharedImages/newsReleasesRO.gif";
		break;
    case "speeches": //What's New - Speeches
   		document.speeches.src="http://www.mackenziegas.ca/sharedImages/speechesRO.gif";
		break;
   case "newsletter": //What's New - Newsletter
   		document.newsletter.src="http://www.mackenziegas.ca/sharedImages/newsletterRO.gif";
		break;
   case "consultationSchedule": //What's New - Consultation Schedule
 		document.consultationSchedule.src="http://www.mackenziegas.ca/sharedImages/consultationScheduleRO.gif";
		break;
   case "regionalOffices": //Contact Us - Regional Offices
 		document.regionalOffices.src="http://www.mackenziegas.ca/sharedImages/regionalOfficesRO.gif";
		break;
   case "questionsAnswers": //More Information - Questions  & Answers
   		document.questionsAnswers.src="http://www.mackenziegas.ca/sharedImages/questionsAnswersRO.gif";
		break;
   case "newsletters": //More Information - Newsletters
   		document.newsletters.src="http://www.mackenziegas.ca/sharedImages/newslettersRO.gif";
		break;
    case "publications": //More Information - Publications
   		document.publications.src="http://www.mackenziegas.ca/sharedImages/publicationsRO.gif";
		break;
   case "newsArchive": //More Information - News Archives
   		document.newsArchives.src="http://www.mackenziegas.ca/sharedImages/newsArchivesRO.gif";
		break;
   case "speechesArchive": //More Information - Speeches
   		document.speechesArchive.src="http://www.mackenziegas.ca/sharedImages/speechesRO.gif";
		break;
   case "projectvideos": //More Information - Project Videos
   		document.projectvideos.src="http://www.mackenziegas.ca/sharedImages/projectvideosRO.gif";
		break;
}
}
