Web App Development Exercise 6
Web App Development Exercise 6
<html>
<head></head>
<body>
<center>
<h1 style="color: green;">
Create Account
</h1>
<h3>
Validate Input Fields
</h3>
<form action="#" method="post">
<label for="fname">First Name:</label>
<input type="text" name="fname" id="fname">
<br><br>
<label for="lname">Last Name:</label>
<input type="text" name="lname" id="lname" >
<br><br>
<label for="email">Email Id:</label>
<input type="email" name="email" id="email" >
<br><br>
<label for="password">Password:</label>
<input type="password" name="password" id="password" >
<br><br>
<label for="phone">Phone Number:</label>
<input type="tel" name="phone" id="phone" >
<br><br>
<input type="submit" value="Submit">
</form>
</center>
</body>
</html>
c) Call the validate() function for onsubmit event handler of the form.