-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex-dev.html
More file actions
79 lines (59 loc) · 2.08 KB
/
index-dev.html
File metadata and controls
79 lines (59 loc) · 2.08 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
<style>
form, form div {
margin-bottom: 10px;
}
label {
width: 100px;
text-align: right;
padding-right: 6px;
display: inline-block;
}
input.error {
border: 1px solid red;
}
div#resultContainer {
border: 1px solid #b8b8b8;
}
div.error {
border-color: red !important;
}
div.success {
border-color: #00e200 !important;
}
div.progress {
border-color: #3c5de2 !important;
}
</style>
</head>
<body>
<div id="debug">
<button onclick='document.getElementById("myForm").setAttribute("action", "mock-responses/success.json"); return false;'>set action success.json</button>
<button onclick='document.getElementById("myForm").setAttribute("action", "mock-responses/error.json"); return false;'>set action error.json</button>
<button onclick='document.getElementById("myForm").setAttribute("action", "mock-responses/progress.json"); return false;'>set action progress.json</button>
<hr/>
</div>
<form id="myForm" action="./mock-responses/success.json" onsubmit="MyForm.submit(); return false;">
<div>
<label for="fio">fio</label>
<input type="text" id="fio" name="fio"/>
</div>
<div>
<label for="email">email</label>
<input type="email" id="email" name="email"/>
</div>
<div>
<label for="tel">tel</label>
<input type="tel" id="tel" name="tel"/>
</div>
<input id="submit" type="submit"/>
</form>
<div id="resultContainer">
</div>
</body>
<script src="index.js"></script>
</html>