hi there,
i am using DMX and sql2000.
I'm very new to JavaScript so please bear with me. I need to verify a password In my form I have username field,old password,new password,verify password.All data needs to be checked on_Submit.I've create a function
<script language="JavaScript" type="text/JavaScript">
<!--
function frmChangePWD_onSubmit()
{
if (document.frmChangePWD.txtNew_PWD.Value != document.frmChangePWD.txtConfirm.Value) {
alert("The password didn't match"
return false;
}
return true;
}
//-->
I'm calling the code in the Form section:
<form action="" method="post" name="frmChangePWD" target="_self" id="frmChangePWD" onSubmit="MM_validateForm('txtUserName','','R','txtOld_PWD','','R','txtNew_PWD','','R','txtConfirm','','R');return document.MM_returnValue && frmChangePWD_onSubmit() ;">
The regular validation function mm_validateform() works by itself, but Once I add another function it ignores my script completely .
What am I doing wrong
Thanks in advance
Nat
i am using DMX and sql2000.
I'm very new to JavaScript so please bear with me. I need to verify a password In my form I have username field,old password,new password,verify password.All data needs to be checked on_Submit.I've create a function
<script language="JavaScript" type="text/JavaScript">
<!--
function frmChangePWD_onSubmit()
{
if (document.frmChangePWD.txtNew_PWD.Value != document.frmChangePWD.txtConfirm.Value) {
alert("The password didn't match"
return false;
}
return true;
}
//-->
I'm calling the code in the Form section:
<form action="" method="post" name="frmChangePWD" target="_self" id="frmChangePWD" onSubmit="MM_validateForm('txtUserName','','R','txtOld_PWD','','R','txtNew_PWD','','R','txtConfirm','','R');return document.MM_returnValue && frmChangePWD_onSubmit() ;">
The regular validation function mm_validateform() works by itself, but Once I add another function it ignores my script completely .
What am I doing wrong
Thanks in advance
Nat