-
Notifications
You must be signed in to change notification settings - Fork 0
/
Form.html
86 lines (79 loc) · 4.27 KB
/
Form.html
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<!DOCTYPE html>
<html lang = "en">
<head>
<meta charset="UTF-8">
<title>JS</title>
<link rel="stylesheet" type="text/css" href="Form.css">
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.0.0/animate.min.css"
/>
<link rel="icon" type="image/ico" href = "cat.ico">
</head>
<body>
<header>
<h1 class="animate__animated animate__fadeInDown"><a href="index.html">WELCOME</a></h1>
<ul class="start">
<li>
<ul class= "menu">
<li class = "menu-item">
<a href="#">МЕНЮ</a>
<ul class="sub-menu">
<li class="for-menu"><a href="index.html">Главная</a></li>
<li class="for-menu"><a href="Form.html">Войти</a></li>
<li class="for-menu"><a href="https://www.free-stock-music.com/lo-fi.html" target="_blank">Сайт с музыкой</a></li>
</ul>
</li>
</ul>
</li>
<li class="input"><a href="Form.html">ВОЙТИ</a>
</li>
</ul>
</header>
<script>
var el = document.getElementsByClassName('menu-item')
for(var i = 0; i<el.length; i++){
el[i].addEventListener('mouseenter', showSub, false); /* при наведении мыши */
el[i].addEventListener('mouseleave', hideSub, false); /* при уходе мыши */
}
function showSub(){
if(this.children.length>1){ /* если в текущего элемента потомков больше одного */
this.children[1].style.height = "auto";
this.children[1].style.opacity = "1";
this.children[1].style.overflow = "visible";
}
else {
return false;
}
}
function hideSub(){
if(this.children.length>1){ /* если в текущего элемента потомков больше одного */
this.children[1].style.height = "0";
this.children[1].style.opacity = "0";
this.children[1].style.overflow = "hidden";
}
else {
return false;
}
}
</script>
<div class="center">
<form class="transparent" name="vhod">
<div class="form-inner">
<h3>Регистрация</h3>
<label for="username">ИМЯ ПОЛЬЗОВАТЕЛЯ</label>
<input type="text" id="username" autocomplete="off" maxlength="50" required placeholder="Имя" pattern="[а-яА-яa-zA-Z]{3,}">
<label for="tel">ТЕЛЕФОН</label>
<input id="tel" type="tel" placeholder="+7(000)-000-0000" autocomplete="off" maxlength="11" required pattern="[0-9]{11}">
<label for="mail">ПОЧТА</label>
<input id="mail" type="email" placeholder="[email protected]" autocomplete="off" maxlength="50" required pattern="(?:[a-z0-9!#$%&'*+/=?^{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_{|}~-]+)|(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\[\x01-\x09\x0b\x0c\x0e-\x7f]))@(?:(?:[a-z0-9](?:[a-z0-9-][a-z0-9])?.)+[a-z0-9](?:[a-z0-9-][a-z0-9])?|[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?).){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-][a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\[\x01-\x09\x0b\x0c\x0e-\x7f])+)])">
<label for="password">ПАРОЛЬ</label>
<input id="password" type="password" autocomplete="off" placeholder="Пароль" required pattern="[0-9a-zA-Z!@#$%^&]{8,}">
<input type="checkbox" id="custom-checkbox">
<label for="custom-checkbox">Запомнить меня</label>
<input type="submit" value="Войти">
</div>
</form>
</div>
</body>
</html>