Skip to content

Commit 4b959c7

Browse files
committed
Update index.html
added name and email with validation
1 parent 32ee3d6 commit 4b959c7

1 file changed

Lines changed: 39 additions & 20 deletions

File tree

Form-Controls/index.html

Lines changed: 39 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,42 @@
11
<!DOCTYPE html>
22
<html lang="en">
3-
<head>
4-
<meta charset="utf-8" />
5-
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
6-
<title>My form exercise</title>
7-
<meta name="description" content="" />
8-
<meta name="viewport" content="width=device-width, initial-scale=1" />
9-
</head>
10-
<body>
11-
<header>
12-
<h1>Product Pick</h1>
13-
</header>
14-
<main>
15-
<form>
16-
17-
</form>
18-
</main>
19-
<footer>
20-
<p>Created by Szidonia Bodo</p>
21-
</footer>
22-
</body>
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
6+
<title>My form exercise</title>
7+
<meta name="description" content="" />
8+
<meta name="viewport" content="width=device-width, initial-scale=1" />
9+
</head>
10+
<body>
11+
<header>
12+
<h1>Product Pick</h1>
13+
</header>
14+
<main>
15+
<form>
16+
<div>
17+
<label for="name">Name</label>
18+
<input
19+
type="text"
20+
name="name"
21+
id="name"
22+
pattern=".*\S.*\S.*"
23+
placeholder="Enter Your Name"
24+
/>
25+
</div>
26+
<div>
27+
<label for="email">Email</label>
28+
<input
29+
type="email"
30+
name="email"
31+
id="email"
32+
required
33+
placeholder="Enter your email address"
34+
/>
35+
</div>
36+
</form>
37+
</main>
38+
<footer>
39+
<p>Created by Szidonia Bodo</p>
40+
</footer>
41+
</body>
2342
</html>

0 commit comments

Comments
 (0)