-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path002.php
219 lines (193 loc) · 5.71 KB
/
002.php
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>第三週-表單設計</title>
<link href="https://fonts.googleapis.com/css?family=Noto+Sans+TC&display=swap" rel="stylesheet">
</head>
<style>
* {
margin: 0;
padding: 0;
}
*:focus {
outline: none;
}
body {
font-family: "微軟正黑體";
justify-content: content;
align-items: center;
height: 100vh;
display: flex;
background-color: #2d4654;
font-family: 'Noto Sans TC', sans-serif;
color: #fff;
}
.form {
width: 500px;
margin: 0 auto;
padding: 20px;
/* border: 1px solid #ccc; */
border-radius: 5px;
gap: 10px;
display: grid;
background-color: #243b4a;
box-shadow: #243b4a 0px 0px 50px;
}
.title {
font-weight: bold;
font-size: 20px;
}
.form input {
padding: 5px;
border: none;
border-radius: 10px;
height: 20px;
background-color: #4e4d5c;
color: #fff
}
/* 移除 input foucus 的外誆 */
.form input:focus {
outline: none;
}
/* hide radio click btn */
.form input[type="radio"] {
display: none;
}
/* custom radio text border */
.form input[type="radio"]+label {
display: inline-block;
padding: 5px 10px;
border: none;
border-radius: 30px;
margin-right: 10px;
cursor: pointer;
background-color: #4e4d5c;
}
/* custom radio text border when click */
.form input[type="radio"]:checked+label {
background: #87bcde;
}
/* hide check box btn */
.form input[type="checkbox"] {
display: none;
}
/* custom check box text border */
.form input[type="checkbox"]+label {
display: inline-block;
padding: 5px 10px;
border: none;
background-color: #4e4d5c;
margin-right: 10px;
cursor: pointer;
}
/* custom check box text border when click */
.form input[type="checkbox"]:checked+label {
background: #87bcde;
}
.form select {
-webkit-appearance: none;
padding: 8px;
border: none;
border-radius: 10px;
color: #fff;
background-color: #4e4d5c;
}
.form selected:focus {
outline: none;
}
.form textarea {
padding: 5px;
border: none;
border-radius: 10px;
background-color: #4e4d5c;
padding: 10px 10px;
color: #fff;
resize: none;
overflow-y: scroll;
}
/* 移除 textarea foucus 的外誆 */
.form textarea:focus {
outline: none;
}
.form input[type="submit"] {
background-color: #805e73;
border: none;
color: #fff;
font-weight: bold;
cursor: pointer;
padding: 10px 20px;
height: auto;
}
.form input[type="submit"]:hover {
background-color: #4e4d5c;
}
.form input[type="reset"] {
background-color: #243b4a;
border: none;
color: #fff;
font-weight: bold;
cursor: pointer;
padding: 10px 20px;
height: auto;
}
.form input[type="reset"]:hover {
background-color: #4e4d5c;
}
.bar {
display: flex;
flex-direction: row;
gap: 5px;
}
</style>
<body>
<form class="form" method="post" action="006.php">
<!-- 學號 -->
<label for="studentID" class="title">學號</label>
<input type="text" name="studentID" id="studentID" placeholder="請輸入學號">
<!-- 姓名 -->
<label for="name" class="title">姓名</label>
<input type="text" name="name" id="name" placeholder="請輸入姓名">
<!-- 性別 -->
<p class="title">性別</p>
<div class="bar">
<input type="radio" id="male" name="gender" value="男">
<label for="male">男</label><br>
<input type="radio" id="female" name="gender" value="女">
<label for="female">女</label><br>
<input type="radio" id="other" name="gender" value="其他">
<label for="other">其他</label><br>
</div>
<!-- 興趣 -->
<p class="title">興趣</p>
<div class="bar">
<input type="checkbox" id="html" name="interest[]" value="寫程式">
<label for="html">寫程式</label><br>
<input type="checkbox" id="css" name="interest[]" value="上網">
<label for="css">上網</label><br>
<input type="checkbox" id="javascript" name="interest[]" value="逛街">
<label for="javascript">逛街</label><br>
<input type="checkbox" id="php" name="interest[]" value="運動">
<label for="php">運動</label><br>
</div>
<!-- 專長 -->
<label for="telent" class="title">專長</label>
<select name="telent" id="telent">
<option value="資訊技術" selected>資訊技術</option>
<option value="資訊管理">資訊管理</option>
<option value="體育項目">體育項目</option>
<option value="金融市場">金融市場</option>
<option value="農業科技">農業科技</option>
</select>
<!-- 建議 -->
<label for="suggestion" class="title">建議</label>
<textarea name="suggestion" id="suggestion" cols="30" rows="10" placeholder="給點建議吧"></textarea>
<div class="bar">
<!-- 送出 -->
<input type="submit" name="submit" value="送出">
<!-- 清除 -->
<input type="reset" value="清除">
</div>
</form>
</body>
</html>