-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathchapter3.html
More file actions
231 lines (193 loc) · 6.2 KB
/
chapter3.html
File metadata and controls
231 lines (193 loc) · 6.2 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
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CHAPTER 3</title>
</head>
<body>
<!-- TABLES IN HTML -->
<table border="1">
<caption>Food Menu</caption>
<thead>
<tr>
<th>Item</th>
<th>Price</th>
</tr>
</thead>
<tbody>
<tr>
<td>Frooti</td>
<td>10</td>
</tr>
<tr>
<td>Samosa</td>
<td>12</td>
</tr>
<tr>
<td>Chips</td>
<td>20</td>
</tr>
</tbody>
</table>
<br>
<!-- colspan and rowspan Attributes -->
<table border="1">
<caption>Food Menu</caption>
<thead>
<tr>
<th rowspan="2">Item</th>
<th colspan="2">Price</th>
</tr>
<tr>
<th>INR</th>
<th>USD</th>
</tr>
</thead>
<tbody>
<tr>
<td>Frooti</td>
<td>10</td>
<td>0.14</td>
</tr>
<tr>
<td>Samosa</td>
<td>12</td>
<td>0.17</td>
</tr>
<tr>
<td>Chips</td>
<td>20</td>
<td>0.28</td>
</tr>
</tbody>
</table>
<br>
<!-- Practice Question for Tables -->
<table border="1">
<caption>A test table with merged cells</caption>
<tbody>
<tr>
<td rowspan="2"></td>
<td colspan="2">Average</td>
<td rowspan="2">Red eyes</td>
</tr>
<tr>
<td>Height</td>
<td>Weight</td>
</tr>
<tr>
<td>Males</td>
<td>1.9</td>
<td>0.003</td>
<td>40%</td>
</tr>
<tr>
<td>Females</td>
<td>1.7</td>
<td>0.002</td>
<td>43%</td>
</tr>
</tbody>
</table>
<br>
<hr>
<br>
<!-- FORMS IN HTML -->
<form action="/demo_server">
<!-- type text -->
<label for="username">Username : </label>
<input type="text" id="username" name="username" placeholder="username">
<br> <br>
<!-- type password -->
<label for="password">Password : </label>
<input type="password" id="password" name="password" placeholder="password">
<br> <br>
<!-- type number -->
<label for="age">Enter Age : </label>
<input type="number" id="age" name="age" placeholder="age">
<br> <br>
<!-- type radio -->
<label for="gender">Gender : </label>
<input type="radio" id="female" name="gender" value="female">
<label for="female">Female</label>
<input type="radio" id="male" name="gender" value="male">
<label for="male">Male</label>
<input type="radio" id="other" name="gender" value="other">
<label for="other">Other</label>
<br> <br>
<!-- type dropdown -->
<label for="nationality">Choose Higher Education : </label>
<select name="nationality" id="nationality">
<option selected>Select</option>
<option value="primary">Primary</option>
<option value="secondary">Secondary</option>
<option value="higher-secondary">Higher-Secondary</option>
<option value="graduate">Graduate</option>
<option value="post-graduate">Post Graduate</option>
<option value="Phd">Phd</option>
<option value="illiterate">Illiterate</option>
</select>
<br> <br>
<!-- type range -->
<label for="volume">Volume : </label>
<input type="range" id="volume" name="volume" min="0" max="100" step="10" value="50">
<br> <br>
<!-- type checkbox -->
<input type="checkbox" id="terms" name="terms">
<label for="terms">I agree to all terms and conditions</label>
<br>
<input type="checkbox" id="cookies" name="cookies" checked>
<label for="cookies">Allow all cookies</label>
<br> <br>
<!-- Text Area -->
<label for="feed">Give Feedback : </label>
<br>
<textarea name="feed" id="feed" placeholder="write here..." rows="5" cols="20"></textarea>
<br> <br>
<!-- BUTTONS ELEMENT -->
<div>
<button type="submit">Submit</button>
<button type="button">Click me</button>
<button type="reset">Reset</button>
</div>
</form>
<br>
<hr>
<!-- Practice Question for Forms -->
<form action="/server">
<h2>Registeration Form</h2>
<input type="text" id="fname" name="fname" placeholder="First Name">
<input type="text" id="lname" name="lname" placeholder="Last Name">
<br><br>
<label for="gender">Select Gender : </label>
<select name="gender" id="gender">
<option selected>select</option>
<option value="female">Female</option>
<option value="male">Male</option>
<option value="other">Other</option>
</select>
<br><br>
<label for="terms">Do you agree to all terms of service?</label>
<input type="checkbox" id="terms" name="terms" selected>
<label for="terms">Yes, I agree</label>
<br><br>
<button type="reset">Reset</button>
<button type="submit">Register</button>
</form>
<br>
<hr>
<!-- NAME ATTRIBUTE -->
<form action="https://www.youtube.com/results?">
<h3>Search at Youtube</h3>
<input type="text" name="search_query" placeholder="Search">
<button type="submit">Search</button>
</form>
<form action="https://www.google.com/search?q=apple">
<h3>Search at Google</h3>
<input type="text" name="q" placeholder="Search in Google">
<button type="submit">Search</button>
</form>
<br>
</body>
</html>