-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtrial.js
37 lines (33 loc) · 930 Bytes
/
trial.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
/* function click(){
window.location="./login.html"
}
function validateemail()
{
var x=document.myform.email.value;
var atposition=x.indexOf("@");
var dotposition=x.lastIndexOf(".");
if (atposition<1 || dotposition<atposition+2 || dotposition+2>=x.length){
alert("Please enter a valid e-mail address");
return false;
}
}
function matchpass(){
var firstpassword=document.f1.password.value;
var secondpassword=document.f1.password2.value;
else{
alert("password must be same!");
return false;
}
} */
function validateform(){
let email=document.form1.name.value;
let firstpassword=document.form1.password.value;
let secondpassword=document.form1.password2.value;
if(firstpassword==secondpassword){
alert("submitted succesfully")
window.location="index1.html"
}
else{
alert("your password is incorrect")
}
}