HTML hidden Attribute
Example
<p hidden>I'm hidden paragraph</p>
<p>I'm visible paragraph</p>
Meaning
The hidden attribute is a Boolean, or presence-based, attribute that does not require a value.
Standard Syntax
HTML: <element hidden>
XHTML: <element hidden="hidden">
Applies to:
The hidden attribute can be used on the following element:
| Element | Attribute |
|---|---|
| Global Attributes | hidden |
| <input> | hidden |
Advertisement
Attribute Values
| Value | Description |
|---|---|
| hidden | This is a boolean attribute, the presence of a boolean attribute on an element represents the true value, and the absence of the attribute represents the false value. |
More Example:
<input type="hidden" id="myHidden" name="myHidden" value="1234">