function hideLayer(whichLayer) {

if (document.getElementById) {
// this is the way the standards work
document.getElementById(whichLayer).style.display = "none";
}
else if (document.all) {
// this is the way old msie versions work
document.all[whichlayer].style.display = "none";
}
else if (document.layers) {
// this is the way nn4 works
document.layers[whichLayer].display = "none";
}

}

function showLayer(whichLayer) {

if (document.getElementById) {
// this is the way the standards work
document.getElementById(whichLayer).style.display = "block";
}
else if (document.all) {
// this is the way old msie versions work
document.all[whichlayer].style.display = "block";
}
else if (document.layers) {
// this is the way nn4 works
document.layers[whichLayer].display = "block";
}

}

function handleClick(whichClick) {

if (whichClick == "hide it") {
// then the user wants to hide the layer
hideLayer("centered");
showLayer("clickLayer");

}
else if (whichClick == "show it") {
// then the user wants to show the layer
showLayer("centered");
hideLayer("clickLayer");
}

else if (whichClick == "showVideo")
	{
	// then the user wants to show the layer
	showLayer("joeVideo");
	showLayer("joeCaption")
	hideLayer("joeText");

}
else if (whichClick == "hideVideo")
	{
	// then the user wants to show the layer
	var player = document.getElementById('mpl');
	player.sendEvent('PLAY', 'FALSE'); 
    showLayer("joeText");
	hideLayer("joeVideo");
	hideLayer("joeCaption");
}
}


function isFieldBlank (theField)
	{
        if (theField.value == '')
        return true;
        else
        return false;
	}
function doSubmit(form)
	{

		foundError = false;
		ErrorMsg = "";
		if (isFieldBlank(form.email))
		{
			ErrorMsg = ErrorMsg + " \nEnter your Email Address.";
			foundError = true;
		}
		
<!-- *** Test Email *** -->

		var InpTwo = form.email.value;
		if (InpTwo == "") {
		}
		else {

	         	var newreg = /@\b/gi;         //set up search parameters
        	 	if (InpTwo.match(newreg)) {   //see if found
                		newarray=InpTwo.match(newreg);
                		if (newarray.length == 1) {

	                 	}
        	         	else {
                	        	ErrorMsg = ErrorMsg + " \nEnter a valid email address.";
                        		foundError = true;
		                }
        		}
         		else {
                        	 ErrorMsg = ErrorMsg + " \nEnter a valid email address.";
        	         	foundError = true;
			}
		}

<!-- *** End Test Email *** -->

		if (foundError == false)
		{
		  	form.submit();
		}
		else
		{ alert (ErrorMsg);
		}		
	}
