-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpuzzle.html
71 lines (45 loc) · 1.6 KB
/
puzzle.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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Title</title>
<link rel="stylesheet" href="style.css">
<script type="text/javascript">
function checkAnswer(){
var result = document.getElementById("answer1").value;
var count = 0;
if (result == "Радуга")
count++;
var result = document.getElementById("answer2").value;
if (result == "Internet")
count++;
alert("Вы ответили правильно на " + count + " загадок");
}
</script>
</head>
<body>
<div id="header">
<a href="index.html">Главная</a><span>/</span>
<a href="puzzle.html">Загадки</a><span>/</span>
<a href="guess.html">Угадайка</a><span>/</span>
<a href="guess-2.html">Угадайка мультиплеер</a>
</div>
<div id="content">
<h1>Игра в загадки</h1>
<div id="box">
<h2>Я загадал несколько загадок, попробуй их угадать!</h2>
<p>Встанет, до небу достанет.</p>
<input type="text" id = "answer1"></input>
<p>Около 40 млн. человек занимаются ЭТИМ по ночам. Что ЭТО такое?</p>
<input type="text" id = "answer2"></input>
<br/>
<a href="#" onclick="checkAnswer()">Ответить</a>
<br></br>
</div>
</div>
</div>
<div id="footer">
Copyright © 2016 <a href="https://geekbrains.ru" target="_blank">GeekBrains</a>
</div>
</body>
</html>