// JavaScript Document
function clientroster_mouseover(id) {
	document.getElementById('client' + id).className = "client_roster_artist_hover";
	document.getElementById('btn_img' + id).src = "http://www.esterman.com/images/button_booknow_hover.jpg";
}

function clientroster_mouseout(id) {
	document.getElementById('client' + id).className = "client_roster_artist";
	document.getElementById('btn_img' + id).src = "http://www.esterman.com/images/button_booknow.jpg"
}

function clientroster_mouseover2(id) {
	document.getElementById('client' + id).className = "client_roster_artist_hover";
	document.getElementById('btn_img' + id).src = "http://www.esterman.com/images/button_booknow_hover.jpg";
}

function clientroster_mouseout2(id) {
	document.getElementById('client' + id).className = "client_roster_artist2";
	document.getElementById('btn_img' + id).src = "http://www.esterman.com/images/button_booknow2.jpg"
}

function selectNotify(mode, section, text) {
	var currentValue = document.getElementById(section).value;
	if (mode == "focus") {
		if ((document.getElementById(section).value == "")  || (document.getElementById(section).value == text )) {
			document.getElementById(section).value = "";
			document.getElementById(section).className = "newsletter_signup_inputbox";
		}
	}
	
	if (mode == "blur") {
		if ((document.getElementById(section).value == "")  || (document.getElementById(section).value == text )) {
			document.getElementById(section).className = "newsletter_signup_inputbox";
			document.getElementById(section).value = text;
		}
		else {
			document.getElementById(section).value = currentValue;
		}
	}	
}

function fieldCheck(mode, section, text) {
	var currentValue = document.getElementById(section).value;
	if (mode == "focus") {
		if ((document.getElementById(section).value == "")  || (document.getElementById(section).value == text )) {
			document.getElementById(section).className = "booking_inputbox";
			document.getElementById(section).value = "";			
		}
	}
	
	if (mode == "blur") {
		if ((document.getElementById(section).value == "")  || (document.getElementById(section).value == text )) {
			document.getElementById(section).className = "booking_inputbox_error";
			document.getElementById(section).value = text;
		}
		else {
			document.getElementById(section).value = currentValue;
		}
	}	
}

function checkForBlanks()
{	
	var returnval;
	blank = false;
	//msg = "All fields are required:\r\r ";
	
	var YourName = (document.getElementById("YourName").value);
	var YourEmail = (document.getElementById("YourEmail").value);
	
	if ((YourName == "") || (YourName == "YOUR NAME"))
	{
		blank = true;
	}
	if ((YourEmail == "") || (YourEmail == "YOUR EMAIL"))
	{
		blank = true
	}
	
	if (blank == true)
	{
		//alert(msg);
		returnval = false;
	}
	else
	{
	returnval = true;
	}
	return returnval;
}

function checkForBlanks_booking()
{	
	var returnval;
	blank = false;
	
	var booking_field = new Array();
	var booking_field_name = new Array();
	
	booking_field_name[0] = "ArtistName";
	booking_field_name[1] = "Date";
	//booking_field_name[2] = "Country";
	booking_field_name[2] = "StateProvince";
	booking_field_name[3] = "City";
	booking_field_name[4] = "LocationVenue";
	booking_field_name[5] = "TimeRequired";
	booking_field_name[6] = "OfferBudgetAmount";
	booking_field_name[7] = "ClientName";
	booking_field_name[8] = "ClientEmail";
	booking_field_name[9] = "ClientPhoneNumber";
	
	booking_field[0] = (document.getElementById("ArtistName").value);
	booking_field[1] = (document.getElementById("Date").value);
	//booking_field[2] = (document.getElementById("Country").value);
	booking_field[2] = (document.getElementById("StateProvince").value);
	booking_field[3] = (document.getElementById("City").value);
	booking_field[4] = (document.getElementById("LocationVenue").value);
	booking_field[5] = (document.getElementById("TimeRequired").value);
	booking_field[6] = (document.getElementById("OfferBudgetAmount").value);
	booking_field[7] = (document.getElementById("ClientName").value);
	booking_field[8] = (document.getElementById("ClientEmail").value);
	booking_field[9] = (document.getElementById("ClientPhoneNumber").value);
	
	for (i = 0; i < booking_field.length; i++)
	{
		if ((booking_field[i] == "") || (booking_field[i] == "THIS FIELD IS REQUIRED"))
		{
			blank = true;
			document.getElementById(booking_field_name[i]).className = "booking_inputbox_error";
			document.getElementById(booking_field_name[i]).value = "THIS FIELD IS REQUIRED";
		}
	}

	
	if (blank == true)
	{
		returnval = false;
	}
	else
	{
	returnval = true;
	}
	return returnval;
}