by Dinesh Thakur Category: HTML

The input "type" = hidden is unusual in the respect that they do not appear in the displayed form. By setting the "type" attribute to hidden, it is possible to transmit default or previously specified text that is hidden from the user to the handling program.

It is a convenient tool for the web designer. It can be used to hold contextual information, such as the name of the form (useful when the same form handles is used for several different forms), where to send the passed data etc. A hidden input does not show up anywhere on the web page. The visitors would not be able to see it unless they see your page source. This input is recognized only by the form handler program mainly CGI (scripts) that receives the user's information from the form.


<INPUTtype="hidden"name="data-id"Value="hidden form data">

 Name: To label the hidden data

Value: It specifies the destination where the hidden form data is to be sent. The value attribute is passed as the form data for the name attribute, but the user cannot see any representation of this form component on the screen and is not prompted to change the form component contents.

One of the best use of the hidden input is to tell the form handler where to send the processed data and where to send your visitor after he fills out your form.


<INPUTtype=hiddenname="send processed data to"Value="">