<!--
function stoperror(){
    return true
}
window.onerror=stoperror

function textCounter(field, countfield, maxlimit) {
if (field.value.length > maxlimit) // if too long...trim it!
field.value = field.value.substring(0, maxlimit);
// otherwise, update 'characters left' counter
else 
countfield.value = maxlimit - field.value.length;
}

function MasterFormValidate(theForm)
{
	var errorDesc = "";

   		//if (theForm.t1.selectedIndex == 0)
  		//{
    		//theForm.t1.focus();
		//	errorDesc +="Age Group\n";
  		//}

   		//if (theForm.t9.value == "")
  		//{
    		//theForm.t9.focus();
		//	errorDesc +="Email address\n";
  		//}

   		//if (theForm.t10.value == "")
  		//{
    		//theForm.t10.focus();
		//	errorDesc +="Retype Email\n";
  		//}


	if ((theForm.wherefrom[0].checked == '') && (theForm.wherefrom[1].checked == ''))
  		{
    		alert("You have not selected that you are from Great Britain & Ireland.\n\n");
    		theForm.wherefrom[0].focus();
    		return (false);
  		}

	if (theForm.wherefrom[1].checked == true)
  		{
    		alert("If you live outside the UK or Ireland then you must contact Rotary in your own country. If you do not know how to do this please send an e-mail to the Youth Exchange department at the Rotary head office in Chicago at youthexchange@rotaryintl.org\n\n");
    		//location.href='non-gbi-application.htm';
    		return (false);
  		}


	if (errorDesc == "")
  		{
			return (true);
  		}
	else
  		{
			alert("There are problem(s) with your submission: you have missing inputs:\n\n" + errorDesc);
			errorDesc = "";
			return (false);
  		}

}

function ShowMsg()
{
    		alert("If you live outside the UK or Ireland then you must contact Rotary in your own country. If you do not know how to do this please send an e-mail to the Youth Exchange department at the Rotary head office in Chicago at youthexchange@rotaryintl.org\n\n");
}
//-->
