-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtask1_5.html
44 lines (31 loc) · 936 Bytes
/
task1_5.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
<!DOCTYPE html>
<html>
<body>
<h1>Web-ôîðìà äëÿ îòïðàâêè êîíòàêòíûõ äàííûõ 3</h1>
<p>ÔÈÎ:</p>
<input type="text" size="40" id="fio">
<p>Òåëåôîí</p>
<input type="text" size="40" id="ph">
<p>Êîììåíòàðèé:</p>
<input type="comment" size="40" id="cm">
<br><br><input type="button" onclick="send_button()" value="Send" id='b_id0'/>
<script>
class Person{
name = "Ivanov Ivan Ivanovich";
phone = "(+7)964-276-42-40";
comment = "25 years old";
constructor(){}
Send(){
return [this.name, this.phone, this.comment];
}
}
function send_button(){
const pr = new Person();
document.getElementById("fio").value = pr.Send()[0];
document.getElementById("ph").value = pr.Send()[1];
document.getElementById("cm").value = pr.Send()[2];
send_function();
}
function send_function(){}
</script>
</body></html>