function checkLeftNav(argNum){
 leftnav?moveLeftNav(argNum,0):moveLeftNav(argNum,1);
 leftnav?leftnav=0:leftnav=1;
 checkFeatures();
}
    
function moveLeftNav(argNum,argDirection){
 var curLeftNavHeight = getH("leftNav" + argNum) - 73;
 var newYPos;
 var indexNumber = argNum + 1;
   
  //Loop and move divs down
 for(i=indexNumber;i<3;i++){
   var indexLeftNav = "leftNav" + i;
   var curYPos = getY(indexLeftNav);
   argDirection?newYPos =  parseInt(curYPos) + parseInt(curLeftNavHeight):newYPos = parseInt(curYPos) - parseInt(curLeftNavHeight);
   setY(indexLeftNav,newYPos);  
 }        
}

//Dodge Life Scripts
var curlifeSection=0;
var curlifeNav="";
var curDodgeFeature="";
var isOpen=false;


function dodgeLifeNavFeature(argImg,argDiv){
  if(argImg != curDodgeFeature){
    swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_off.gif',argDiv);
  }else{
    swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_on.gif',argDiv);
  }
}

function dodgeLifeNavOn(argImg,argDiv){
  swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_on.gif',argDiv);
}

function dodgeLifeNavOff(argImg,argDiv){
  if(curlifeNav != argImg){
    swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_off.gif',argDiv);
  }
}

function checkdodgeLifeNav(argNum,argImg){
	var navHeight;
	var newYPos;
	var indexNumber;
	
	//owners link has changed to redirect to acutal owners page
	if (argNum === 1) document.location = "/en/owners/";
	if (argNum === 1) return;
	
	//news link has changed to redirect to acutal news page
	if (argNum === 2) document.location = "/en/experience/news/";
	if (argNum === 2) return;

	swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_on.gif',['leftNav'+ argNum]);

	if (isOpen == true) {
		navHeight = getH("leftNav" + curlifeSection) - 45;
		indexNumber = curlifeSection + 1;
		for (i = indexNumber; i < 7; i++) {
			var indexLeftNav = "leftNav" + i;
			var curYPos = getY(indexLeftNav);
			newYPos =  parseInt(curYPos) - parseInt(navHeight);
			setY(indexLeftNav,newYPos);
		}
		isOpen = false;
		swapImg(curDodgeFeature,'/carryover/nav/dodge_life/'+ curDodgeFeature +'_off.gif',['leftNav'+ curlifeSection]);
		curDodgeFeature = "";
	}

	if (argNum != curlifeSection) {
		navHeight = getH("leftNav" + argNum) - 45;		
		indexNumber = argNum + 1;
		for (i = indexNumber; i < 7; i++) {
			var indexLeftNav = "leftNav" + i;
			var curYPos = getY(indexLeftNav);
			newYPos =  parseInt(curYPos) + parseInt(navHeight);
			setY(indexLeftNav,newYPos);
		}
		isOpen = true;
		curlifeSection = argNum;
		curDodgeFeature = argImg;
	}
	else {
		swapImg(argImg,'/carryover/nav/dodge_life/'+ argImg +'_off.gif',['leftNav'+ curlifeSection]);
		curlifeSection = 0;
		curDodgeFeature = "";
	}
}

//var events = document.getElementById('leftNav3').getElementsByTagName("a")[2];
