Basic HTML code to make a simpleForm
Paste the code and save with .html extension.
<html>
<head>
<title>Form creation || Nested Code Publication</title>
</head>
<body>
<center><h1>::This is the Sample Registration Form::</h1></center><hr><br>
<!-- Table will be created here -->
<center>
<div align= "center" style="width:350px;height:200px;border:6px inset orange;padding: 12px;">
<form name="f" method="post" action=" ">
<table >
<!-- 1st row -->
<tr>
<td>Name</td>
<td><input type="text"></td>
</tr>
<!-- 2nd row -->
<tr>
<td>Address</td>
<td><textarea></textarea></td>
</tr>
<!-- 3rd row -->
<tr>
<td>Sex</td>
<td><input type="radio" name="radiobutton">Male
<input type="radio" name="radiobutton">Female</td>
</tr>
<!-- 4th row -->
<tr>
<td>City</td>
<td><select>
<option>Kolkata</option>
<option>Delhi</option>
<option>Ranchi</option>
<option>Mumbai</option>
</select>
</td>
</tr>
<tr>
<td><input type="submit" value="Submit"></td>
<td><input type="Reset"></td>
</tr>
</table>
</form>
</div></center><br><br><br><br><hr>
</body>
</html>
HERE IS TEH OUTPUT ::
<head>
<title>Form creation || Nested Code Publication</title>
</head>
<body>
<center><h1>::This is the Sample Registration Form::</h1></center><hr><br>
<!-- Table will be created here -->
<center>
<div align= "center" style="width:350px;height:200px;border:6px inset orange;padding: 12px;">
<form name="f" method="post" action=" ">
<table >
<!-- 1st row -->
<tr>
<td>Name</td>
<td><input type="text"></td>
</tr>
<!-- 2nd row -->
<tr>
<td>Address</td>
<td><textarea></textarea></td>
</tr>
<!-- 3rd row -->
<tr>
<td>Sex</td>
<td><input type="radio" name="radiobutton">Male
<input type="radio" name="radiobutton">Female</td>
</tr>
<!-- 4th row -->
<tr>
<td>City</td>
<td><select>
<option>Kolkata</option>
<option>Delhi</option>
<option>Ranchi</option>
<option>Mumbai</option>
</select>
</td>
</tr>
<tr>
<td><input type="submit" value="Submit"></td>
<td><input type="Reset"></td>
</tr>
</table>
</form>
</div></center><br><br><br><br><hr>
</body>
</html>
HERE IS TEH OUTPUT ::
No comments:
Post a Comment