HTML Form

HTML Form is a part of Web page that consist of plaint text, html elements, and controls. Plain text and html are used to make the structure of the form.Controls which are used in forms are known as field.

Some Attribute of the form are:

action :- it point out that on which page the action will be formed.

autocomplete: Enables the autocomplete feature in a form.

method: it specify that how you want send the information in a browser. Normally we use two method in a form are get, post.

name: Refers to the name of the form.

target: Opens the action URl in the specified target, such as in the same window, in a new window, or in a new tab.

HTML Form Input Element :-

Input Element is used to display the text boxes on a form. These field are used to provide input from the users.

Example of Input :-

<HTML>

<HEAD><TITLE>Input tag in a form</TITLE>

<BODY>

<FORM>

Enter your name: <input>

</FORM>

</BODY>

</HTML>

 

html form

 

HTML Form Input Element , we can add the following fields on a form:- 

  • Text 
  • Password
  • Hidden
  • Checkbox
  • Radio
  • Submit
  • Reset

 Code with HTML Form  input Element and text with textmaxlen:-

<HTML>

<HEAD><TITLE>use of maxlength</TITLE></HEAD>

<BODY>

Enter your 2 digit Code number : <input type=”text” name=”username” size=”2″ maxlength=”2″>

</BODY>

</HTML>

Result:-

html maxlength




Follow Us

Contact Us

tutorialworldin@yahoo.com

Back to Top