-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcc_Survey.html
More file actions
88 lines (83 loc) · 3.94 KB
/
cc_Survey.html
File metadata and controls
88 lines (83 loc) · 3.94 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
80
81
82
83
84
85
86
87
88
<!DOCTYPE html>
<html>
<head>
<title>Experience Rads</title>
<link rel="stylesheet" href="CSS/cc_Survey.css">
</head>
<body>
<H1 id="title">Survey Form</H1>
<p id="description"> A dummy form for the course.</p>
<div id="form-container">
<form id="survey-form">
<label for="name" id="name-label">Enter Name: </label><br>
<input type="text" id="name" name="name" required placeholder="John Matrix"><br>
<label for="email" id="email-label">Enter Email: </label><br>
<input type="email" id="email" name="email" required placeholder="jai3977@yahoo.com.au"><br>
<label for="number" id="number-label">Enter Number: </label><br>
<input type="number" id="number" name="number" required min="10" max="100" placeholder="0400000000"><br><br>
<select id="dropdown" name="dropdown">
<option value="volvo">Volvo</option>
<option value="saab">Saab</option>
<option value="fiat">Fiat</option>
<option value="audi">Audi</option>
</select><br><br>
<input type="radio" id="male" name="gender" value="male">
<label for="male">Male</label>
<input type="radio" id="female" name="gender" value="female">
<label for="female">Female</label><br>
<input type="checkbox" id="Short" name="height" value="Short">
<label for="Short">I am short</label>
<input type="checkbox" id="Average" name="height" value="Average">
<label for="Short">I am Average</label>
<input type="checkbox" id="Tall" name="height" value="Tall">
<label for="Short">I am Tall</label><br>
<label for="comments">Additional Comments</label><br>
<textarea id="textarea" name="textarea"></textarea><br>
<input type="submit" id="submit" value="submit">
</div>
<!-- Start of Button w/ Modal Component -->
<button id="myBtn">Site<br>Info</button>
<div id="myModal" class="modal">
<div class="modal-content"> <!-- Modal content -->
<span class="close">×</span>
<h4>Survey Page</h4>
<p>A survey page I made for the FCC Responsive Website Design Course.<br> Code: HTML, CSS and JavaScript (Only for this button so far).<br> Hosting: nginx.<br> Misc: Git, GitHub.<br>Last Updated: 14/07/2020. </p>
</div>
</div>
<!-- End of Button w/ Modal Component -->
<footer id="ER-footer">
<h6 id="ER-footer-header">experience<strong>Rads</strong> network</h6>
<div id="ER-footer-div">
<a class="ER-footer-link" href="index.nginx-debian.html">experienceRads</a>
<a class="ER-footer-link" href="cc_Portfolio.html">Jai's Portfolio</a>
<a class="ER-footer-link" href="cc_TechnicalPage.html">Technical Page</a>
<a class="ER-footer-link" href="cc_LandingPage.html">Landing Page</a>
<a class="ER-footer-link" href="cc_Survey.html">Survey Form</a>
<a class="ER-footer-link" href="cc_TributePage.html">TributePage</a>
</div>
</footer>
</body>
<script>
// Start of Button w/ Modal component
// Get the modal
var modal = document.getElementById("myModal");
// Get the button that opens the modal
var btn = document.getElementById("myBtn");
// Get the <span> element that closes the modal
var span = document.getElementsByClassName("close")[0];
// When the user clicks the button, open the modal
btn.onclick = function() {
modal.style.display = "block";
}
// When the user clicks on <span> (x), close the modal
span.onclick = function() {
modal.style.display = "none";
}
// When the user clicks anywhere outside of the modal, close it
window.onclick = function(event) {
if (event.target == modal) {
modal.style.display = "none";
}}
// End of Button w/ Modal component
</script>
</html>