HTML Required AttributeThe HTML Required attribute is a Boolean attribute which specifies that the input element must be filled out before the submission of form. This attribute used with the following elements: We can easily use the required attribute with the element as shown in the following syntax: |
Example
Output:
We can easily use the required attribute with the element as shown in the following syntax:
Example
Output:
We can also easily use the required attribute with the element as shown in the following syntax:
Example
Output:
Element | Chrome | IE | Firefox | Opera | Safari |
Yes | Yes | Yes | Yes | Yes |