-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
164 lines (160 loc) · 5.88 KB
/
index.html
File metadata and controls
164 lines (160 loc) · 5.88 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Formulários</title>
<link rel="stylesheet" href="css/styles.css">
</head>
<body>
<h2>Formulários em HTML</h2>
<!-- 1 - Primeiro formulario -->
<!-- 2 - Atributos do formulário -->
<form action="register.js" method="get">
<div>
<label>Nome: </label>
<input type="text">
</div>
<!-- 3 - Atributo name -->
<div>
<!-- 4 - Atributo label -->
<label for="age">Idade:</label>
<input type="text" name="age" />
</div>
<!-- 6 - Select -->
<div>
<label for="job">Selecione a sua profissão:</label>
<select name="job">
<option value="programador">Programador</option>
<option value="tester">Tester/QA</option>
<option value="devops">DevOps</option>
</select>
</div>
<!-- 7 - Atributo selected -->
<div>
<label for="contract">Você leu os termos do contrato?</label>
<select name="contract">
<option value="sim">Sim</option>
<option value="nao" selected>Não</option> <!-- exibi a opção selecionada -->
<select>
</div>
<!-- 8 - Multiplas opções -->
<div>
<label for="items">Selecione os itens desejados:</label>
<select name="items" multiple>
<option value="pera">Pera</option>
<option value="feijao">Feijão</option>
<option value="arroz">Arroz</option>
<option value="milho">Milho</option>
</select>
</div>
<!-- 9 - Textarea -->
<div>
<label for="comment">Escreva abaixo o que você achou do post:</label>
<textarea name="comment"></textarea>
</div>
<!-- 10 - Fieldset e legend -->
<div>
<fieldset>
<legend>Preencha as suas informações:</legend>
<label for="firstname">Nome:</label>
<input type="text" name="firstname">
<label for="lastname">Sobrenome:</label>
<input type="text" name="lastname">
</fieldset>
</div>
<!-- 11 - Datalist -->
<div>
<label for="flavor">Escolha o sabor:</label>
<input type="text" list="flavors" name="flavor">
<datalist id="flavors">
<option value="Cereja"></option>
<option value="Morango"></option>
<option value="Abacaxi"></option>
<option value="Chocolate"></option>
</datalist>
</div>
<!-- 12 - Senha -->
<div>
<label for="password">Digite a sua senha:</label>
<input type="password" name="password">
</div>
<!-- 14 - Radio button -->
<div>
<label for="car_model">Escolha o modelo do seu carro:</label>
<div class="radio">
<input type="radio" value="bmw" name="car_model">
<label for="bmw">BMW</label>
</div>
<div class="radio">
<input type="radio" value="ferrari" name="car_model">
<label for="ferrari">Ferrari</label>
</div>
<div class="radio">
<input type="radio" value="renault" name="car_model">
<label for="renault">Renault</label>
</div>
</div>
<!-- 15 - 'Checkbox' -->
<div>
<label for="optionals">Opcionais do carro:</label>
<div class="radio">
<input type="checkbox" name="optionals[]" value="big_tires">
<label for="big_tires">Pneus Grandes</label>
</div>
<div class="radio">
<input type="checkbox" name="optionals[]" value="turbo_engine">
<label for="turbo_engine">Motor Turbo</label>
</div>
<div class="radio">
<input type="checkbox" name="optionals[]" value="hybrid">
<label for="hybrid">Híbrido</label>
</div>
</div>
<!-- 16 - Datas -->
<div>
<label for="birthday">Data de nascimento:</label>
<input type="date" name="birthday">
</div>
<!-- 17 - Arquivos -->
<div>
<label for="image">Insira a sua imagem:</label>
<input type="file" name="image">
</div>
<!-- 18 - Numeros -->
<div>
<label for="salary">Quanto você ganha no seu emprego atual?</label>
<input type="number" name="salary">
</div>
<!-- 19 - E-mails -->
<div>
<label for="email">Digite o seu e-mail:</label>
<input type="email" name="email">
</div>
<!-- 20 - Value -->
<div>
<label for="value">Digite algum valor:</label>
<input type="text" value="O meu valor é este 2" name="value">
</div>
<!-- 21 - Disabled -->
<div>
<p>Tente mudar o valor:</p>
<input type="text" value="Não precisa preencher" disabled>
</div>
<!-- 22 - Placeholder -->
<div>
<label for="currentjob">Digite a sua profissão:</label>
<input type="text" name="currentjob" placeholder="No que você está trabalhando agora?">
</div>
<!-- 23 - Required -->
<div>
<label for="birthyear">Ano nascimento:</label>
<input type="text" placeholder="Digite o ano em que você nasceu" required>
</div>
<!-- 13 - Resetar form -->
<input type="reset" value="Limpar">
<!-- 5 - Envio de form -->
<input type="submit" value="Enviar" />
</form>
</body>
</html>