function changeColor(color, ID) 
{
	if (color != '#NONE')
	{	
		document.getElementById(ID).bgColor = "#" + color;
		document.getElementById(ID).style.cursor='pointer';
	}
	else 
	{
		document.getElementById(ID).bgColor = null;
		document.getElementById(ID).style.cursor='pointer';
	}
}

function checkReserveTickets()
{
if (document.RESERVETICKETS.NAME.value.length == 0)
	{
	alert('Please enter your name to reserve ticktes.');
	document.RESERVETICKETS.NAME.focus();
	}
else if (document.RESERVETICKETS.ADDRESS.value.length == 0)
	{
	alert('Please enter your address to reserve ticktes.');
	document.RESERVETICKETS.ADDRESS.focus();
	}
else if (document.RESERVETICKETS.CITY.value.length == 0)
	{
	alert('Please enter your city to reserve ticktes.');
	document.RESERVETICKETS.CITY.focus();
	}
else if (document.RESERVETICKETS.STATE.value == 0)
	{
	alert('Please enter your state to reserve ticktes.');
	document.RESERVETICKETS.STATE.focus();
	}
else if (document.RESERVETICKETS.ZIP.value.length < 5)
	{
	alert('Please enter a correct zip code to reserve ticktes.');
	document.RESERVETICKETS.ZIP.focus();
	}
else if (document.RESERVETICKETS.PHONE.value.length < 10)
	{
	alert('Please enter a correct phone number to reserve ticktes.');
	document.RESERVETICKETS.PHONE.focus();
	}
else if((document.RESERVETICKETS.EMAIL.value.length == 0) || (document.RESERVETICKETS.EMAIL.value.indexOf('@')==-1)) 
	{
	alert('You must enter a valid e-mail address to reserve tickets.');
	document.RESERVETICKETS.EMAIL.focus();
	}	
else if (document.RESERVETICKETS.MONTH.value == 0)
	{
	alert('Please enter a month of show to reserve ticktes.');
	document.RESERVETICKETS.MONTH.focus();
	}	
else if (document.RESERVETICKETS.DAY.value == 0)
	{
	alert('Please enter a day of show to reserve ticktes.');
	document.RESERVETICKETS.DAY.focus();
	}	
else if((document.RESERVETICKETS.SENIOR.value == 0) && (document.RESERVETICKETS.ADULT.value == 0) && (document.RESERVETICKETS.STUDENT.value == 0)) 
	{
	alert('You must select either senior, adult, or student tickets.');
	document.RESERVETICKETS.ADULT.focus();
	}		
else 
	{
	alert('Thank you for reserving your tickets with insighttheatrecompany.com.');
	document.RESERVETICKETS.submit();
	}
}

function checkContactUs()
{
if (document.CONTACTUS.NAME.value.length == 0)
	{
	alert('Please enter your name.');
	document.CONTACTUS.NAME.focus();
	}
else if((document.CONTACTUS.EMAIL.value.length == 0) || (document.CONTACTUS.EMAIL.value.indexOf('@')==-1)) 
	{
	alert('You must enter a valid e-mail address.');
	document.CONTACTUS.EMAIL.focus();
	}	
else if (document.CONTACTUS.COMMENTS.value.length == 0)
	{
	alert('Please enter a question or a comment.');
	document.CONTACTUS.COMMENTS.focus();
	}	
else 
	{
	alert('Thank you for your inquiry to insighttheatrecompany.com.');
	document.CONTACTUS.submit();
	}
}