sponsor

sponsor
Theme images by kelvinjay. Powered by Blogger.

Facebook

Search This Blog

Popular Posts

Header Ads

CONTACT US

Recent Tube

Business

Technology

Life & style

Games

Sports

Fashion

» » How to Create Registration Form with HTML Code for website

EXAMPLE OF HTML REGISTRATION FORM
In this tutorial you will learn to create a student registration form using html code in easy steps. In this example given below, you will find several text fields required to fill in a registration form, radio button, Reset button and Submit Form button. The Reset button will reset the form to blank.

In this tutorial for writing html code for student registration form JavaScript validation has been used. Moreover, if you do not enter any value in the text fields, an error message will appear. In this registration form, filling up every field is mandatory and will show an error message if any field is left blank. Further changes can be made as per the requirements by the programmer. Once all the fields are filled correctly, submit form adds the data.

 USE THIS CODE BELOW
 
<html>
  <head>
  <script type="text/javascript" src="validate.js"></script>
  </head>
  <body>
  <form action="#" name="StudentRegistration" onSubmit="return(validate());">
<table cellpadding="2" width="20%" bgcolor="99FFFF" align="center" cellspacing="2">
<tr>
  <td colspan=2>
  <center><font size=4><b>Registration Form</b></font></center>
  </td>
  </tr>
<tr>
  <td>Name</td>
  <td><input type=text name=textnames id="textname" size="30"></td>
  </tr>
<tr>
  <td>Father Name</td>
  <td><input type="text" name="fathername" id="fathername"
  size="30"></td>
  </tr>
  <tr>
  <td>Postal Address</td>
  <td><input type="text" name="paddress" id="paddress" size="30"></td>
  </tr>
<tr>
  <td>Personal Address</td>
  <td><input type="text" name="personaladdress"
  id="personaladdress" size="30"></td>
  </tr>
<tr>
  <td>Sex</td>
  <td><input type="radio" name="sex" value="male" size="10">Male
  <input type="radio" name="sex" value="Female" size="10">Female</td>
  </tr>
<tr>
  <td>City</td>
  <td><select name="City">
  <option value="-1" selected>select..</option>
  <option value="MBEYA">MBEYA</option>
  <option value="DODOMA">DODOMA</option>
  <option value="ARUSHA">ARUSHA</option>
  <option value="MORORGORO">MOROGORO</option>
  </select></td>
  </tr>
<tr>
  <td>Course</td>
  <td><select name="Course">
  <option value="-1" selected>select..</option>
  <option value="B.Tech">B.TECH</option>
  <option value="MCA">MCA</option>
  <option value="MBA">MBA</option>
  <option value="BCA">BCA</option>
  </select></td>
  </tr>
<tr>
  <td>District</td>
  <td><select name="District">
  <option value="-1" selected>select..</optio
  <option value="Nalanda">NALANDA</option>
  <option value="KYELA">KYELA</option>
  <option value="TUKUYU">TUKUYU</option>
  <option value="ILEJE">ILEJE</option>
  </select></td>
</tr>
<tr>
  <td>State</td>
  <td><select Name="State">
  <option value="-1" selected>select..</option>
  <option value="MBEYA">MBEYA</option>
  <option value="ARUSHA">ARUSHA</option>
  <option value="MOROGORO">MOROGORO</option>
  <option value="DODOMA">DODOMA</option>
  </select></td>
  </tr>
  <tr>
  <td>PinCode</td>
  <td><input type="text" name="pincode" id="pincode" size="30"></td>
</tr>
  <tr>
  <td>EmailId</td>
  <td><input type="text" name="emailid" id="emailid" size="30"></td>
  </tr>
<tr>
  <td>DOB</td>
  <td><input type="text" name="dob" id="dob" size="30"></td>
  </tr>
<tr>
  <td>MobileNo</td>
  <td><input type="text" name="mobileno" id="mobileno" size="30"></td>
  </tr>
  <tr>
  <td><input type="reset"></td>
  <td colspan="2"><input type="submit" value="Submit Form" /></td>
  </tr>
  </table>
  </form>
  </body>
  </html>

«
Next
Newer Post
»
Previous
This is the last post.

No comments:

Leave a Reply