/******************************************************************************
Name:       mouseOverMenu
Parameters: element_name
				The name of the element in the document whose class type we are 
				going to change.
            
Return:     None.
Desc:       Change the class type of the document object specified by the 
				parameter 'element_name'.
******************************************************************************/
function mouseOverMenu(element_name) { 

	// Gotta see if this is internet explorer or something else
	var ie = document.getElementById(element_name).getAttribute("class");
	
	// If this is IE...
	if(ie != null) {
		document.getElementById(element_name).setAttribute("class", "button_on");
	}
	
	// This is not IE...
	else {
		document.getElementById(element_name).setAttribute("className", "button_on", 0);
	}
}

/******************************************************************************
Name:       mouseOutMenu
Parameters: element_name
				The name of the element in the document whose class type we are 
				going to change.
            
Return:     None.
Desc:       Change the class type of the document object specified by the 
				parameter 'element_name'.
******************************************************************************/
function mouseOutMenu(element_name) {
	
	// Gotta see if this is internet explorer or something else
	var ie = document.getElementById(element_name).getAttribute("class");
	
	// If this is IE...
	if(ie != null) {
		document.getElementById(element_name).setAttribute("class", "button_off");
	} 
	
	// This is not IE...
	else {
		document.getElementById(element_name).setAttribute("className", "button_off", 0); 
	}
}

/******************************************************************************
Name:       onZoomIn
Parameters: None.
Return:     None.
Desc:       Load the zoomed in map image
******************************************************************************/
function onZoomIn() {

	// Gotta see if this is internet explorer or something else...
	var ie = document.getElementById("map_image").getAttribute("class");
	
	// If this is IE...
	if(ie != null) {
		document.getElementById("map_image").setAttribute("src", "images/map_in.gif");
	} 

	// This is not IE...
	else {
		document.getElementById("map_image").setAttribute("src", "images/map_in.gif", 0); 
	}
}

/******************************************************************************
Name:       onZoomOut
Parameters: None.
Return:     None.
Desc:       Load the zoomed in map image
******************************************************************************/
function onZoomOut() {
	
	// Gotta see if this is internet explorer or something else
	var ie = document.getElementById("map_image").getAttribute("class");
	
	// If this is IE...
	if(ie != null) {
		document.getElementById("map_image").setAttribute("src", "images/map_out.gif");
	} 
	
	// This is not IE...
	else {
		document.getElementById("map_image").setAttribute("src", "images/map_out.gif", 0); 
	}
}

/******************************************************************************
Name:       OnClickTeam
Parameters: None.
Return:     None.
Desc:       Navigate to a randome team rider page
******************************************************************************/
function OnClickTeam()
{		
	var roundedVal = "";
	
	roundedVal = parseInt(Math.random() * 15);
	
	if(roundedVal == "0") 	
		window.location = "team.htm?content=chrismurphy";  
	else if(roundedVal == "1") 	
		window.location = "team.htm?content=jeremyadamich";  
	else if(roundedVal == "2") 	
		window.location = "team.htm?content=hamiltonlynn";  
	else if(roundedVal == "3") 	
		window.location = "team.htm?content=robmurdock";  
	else if(roundedVal == "4") 	
		window.location = "team.htm?content=christianmoore";  
	else if(roundedVal == "5") 
		window.location = "team.htm?content=matthughes";  
	else if(roundedVal == "6") 
		window.location = "team.htm?content=tyrelthornton";  
	else if(roundedVal == "7") 
		window.location = "team.htm?content=markthieszen";  
	else if(roundedVal == "8") 
		window.location = "team.htm?content=koreykaczmarek";  
	else if(roundedVal == "9")	
		window.location = "team.htm?content=robkingwill";  
	else if(roundedVal == "10") 
		window.location = "team.htm?content=chrisankeny";  
   else if(roundedVal == "11")
		window.location = "team.htm?content=toddkirby";
   else if(roundedVal == "12")
		window.location = "team.htm?content=codyearnest";
   else if(roundedVal == "13")
      window.location = "team.htm?content=kevinfischer";
   else if(roundedVal == "14")
      window.locaiton = "team.htm?content=shanestalling";
   else
      window.location = "team.htm?content=kealacole";
      
	return true;
}

/******************************************************************************
Name:       OnClickTeamBackOne
Parameters: None.
Return:     None.
Desc:       Navigate to a randome team rider page
******************************************************************************/
function OnClickTeamBackOne()
{		
	var roundedVal = "";
	
	roundedVal = parseInt(Math.random() * 15);
	
	if(roundedVal == "0") 	
		window.location = "../team.htm?content=chrismurphy";  
	else if(roundedVal == "1") 	
		window.location = "../team.htm?content=jeremyadamich";  
	else if(roundedVal == "2") 	
		window.location = "../team.htm?content=hamiltonlynn";  
	else if(roundedVal == "3") 	
		window.location = "../team.htm?content=robmurdock";  
	else if(roundedVal == "4") 	
		window.location = "../team.htm?content=christianmoore";  
	else if(roundedVal == "5") 
		window.location = "../team.htm?content=matthughes";  
	else if(roundedVal == "6") 
		window.location = "../team.htm?content=tyrelthornton";  
	else if(roundedVal == "7") 
		window.location = "../team.htm?content=markthieszen";  
	else if(roundedVal == "8") 
		window.location = "../team.htm?content=koreykaczmarek";  
	else if(roundedVal == "9")	
		window.location = "../team.htm?content=robkingwill";  
	else if(roundedVal == "10") 
		window.location = "../team.htm?content=chrisankeny";  
   else if(roundedVal == "11")
		window.location = "../team.htm?content=toddkirby";
   else if(roundedVal == "12")
		window.location = "../team.htm?content=codyearnest";
   else if(roundedVal == "13")
      window.location = "../team.htm?content=kevinfischer";
   else if(roundedVal == "14")
      window.locaiton = "../team.htm?content=shanestalling";
   else
      window.location = "../team.htm?content=kealacole";
   
	return true;
}
