Jump to content

firefox


user4fun

Recommended Posts

<script language="javascript"   type="text/javascript">function validateForm(register){if(""==document.forms.register.FName.value){alert("Please enter your first name.");return false;}}

and it gets repeated for other fields.tested in IE and they all work

Link to comment
Share on other sites

Give the form an ID in addition to the name. And instead of this:return validateForm(register);do this:return validateForm(this);Then you can change your function to this:

function validateForm(frm){  if(""==frm.FName.value)  {	alert("Please enter your first name.");	return false;  }}

Make sure the text field also has an id.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...