Hello From Raaj,
I have to some problem to write down the code of email validation. How can I check the email valid or not ? May you help me please. I have write the code of email validation . see here
<SCRIPT language="javascript">
function submitit()
{
var form=document.sendmail ;
if(form.to.value=="")
{
alert('Please Enter the Email Address');
return false;
}
if (form.to.value!="")
{
pass = form.to.value.indexOf('@',0);
pass1 = form.to.value.indexOf('.',0);
if((pass==-1) || (pass1==-1))
{
alert ("Not an valid Email Address");
form.to.focus();
return(false);
}
else if(form.from.value=="")
{
alert('Please Enter your Email Address');
return false;
}
if (form.from.value!="")
{
pass = form.from.value.indexOf('@',0);
if((pass==-1) )
{
pass1 = form.from.value.indexOf('.',0);
if(pass1==-1)
{
alert ("Not an valid email address");
form.from.focus();
return(false);
}
}
else
{
form.submit();
}
}
}
}
</SCRIPT>
This is my code. But this not working properly.
If I have given the aa.aa@ then he has taken. not check if true or not.
Please give me replly soon.
Thanks !