// JavaScript Document
function switchMaps(switchTo)
{
		
	var temp_map_holder = document.getElementById("temp_map_holder");
	var current_map_holder = document.getElementById("maps_holder");
	var replacement_html = temp_map_holder.innerHTML;
	var old_html = current_map_holder.innerHTML;
	
	current_map_holder.innerHTML = replacement_html;
	temp_map_holder.innerHTML = old_html;
	
	var google_menu_item = document.getElementById("google_menu_item");
	var boomyeah_menu_item = document.getElementById("boomyeah_menu_item");
	
	switch(switchTo)
	{		
		case 'google':			
			google_menu_item.className = "maps_selected_menu_item";
			boomyeah_menu_item.className = "maps_non_selected_menu_item";
			loadGMap();
			break;
		case 'boomyeah':			
			google_menu_item.className = "maps_non_selected_menu_item";
			boomyeah_menu_item.className = "maps_selected_menu_item";
			break;
	}
}

function showStars(star_num, starMode)
{
	var star_array = Array(star_num);	
	for(i=0; i<star_num; i++)
	{
		star_array[i] = document.getElementById(starMode + "Star" + (i+1));
		star_array[i].src = '/images/transstar.gif';
	}
}
function hideStars(startNum, starMode)
{
	var score = document.getElementById("review_score");
	var num_stars = score.value;
	var star_array = Array(5);
	for(i=startNum; i<(startNum+5); i++)
	{
		if (num_stars<(i+1))
		{
			star_array[i] = document.getElementById(starMode + "Star" + (i+1));
			star_array[i].src = '/images/empty_star.gif';
		}
	}
}
function updateStars(star_num, starMode, startNum)
{
	var score = document.getElementById("review_score");
	score.value=star_num;
	hideStars(startNum, starMode);
}

function showVideoSponsor()
{
	var video = document.getElementById("mainVideo2");
	video.style.visibility = "visible";
}


function hideVideoSponsor()
{
	var video = document.getElementById("mainVideo2");
	video.style.visibility = "hidden";
}
