Menu
Hi
I am trying to stop a form being submitted if a valid location hasn’t been selected.
The code that isn’t working yet is,
<script language=”Javascript”>
function errorMessages()
{
valid=true;
if (document.form1.selectLocation.selectedIndex == 0)
{
alert (“Please select a valid location.”);
valid = false;
}
return valid;
</script>
Each time my form is just going through – how can I fix it?
Thanks