HTML <fieldset> Tag

Example Group related elements in a form: <form> <fieldset> <legend>Personalia:</legend> Name: <input type=”text”><br> Email: <input type=”text”><br> Date of birth: <input type=”text”> </fieldset> </form> Try it Yourself » Definition and Usage The <fieldset> tag is used to group related elements in a form. The <fieldset> tag draws a box around the related elements. Browser Support Element <fieldset> Yes Yes Yes Yes Yes […]

HTML <fieldset> name Attribute

Example A <fieldset> with a name attribute: <fieldset name=”personalia”> Name: <input type=”text”><br> Email: <input type=”text”><br> </fieldset> Try it Yourself » Definition and Usage The name attribute specifies a name for a fieldset. The name attribute is used to reference elements in a JavaScript, or to reference form data after a form is submitted. Browser Support Attribute name Yes Not supported […]

HTML <fieldset> form Attribute

Example A <fieldset> element located outside a form (but still a part of the form): <form action=”/action_page.php” method=”get” id=”form1″> What is your favorite color? <input type=”text” name=”fav_color”><br> <input type=”submit”> </form> <fieldset form=”form1″> Name: <input type=”text” name=”username”><br> Email: <input type=”text” name=”usermail”><br> </fieldset> Try it Yourself » Definition and Usage The form attribute specifies one or more forms the fieldset belongs to. Browser Support Attribute form Not supported Not supported Not […]

HTML <fieldset> disabled Attribute

Example Disable a group of related form elements: <fieldset disabled> <legend>Personalia:</legend> Name: <input type=”text”><br> Email: <input type=”text”><br> Date of birth: <input type=”text”> </fieldset> Try it Yourself » Definition and Usage The disabled attribute is a boolean attribute. When present, it specifies that a group of related form elements (a fieldset) should be disabled. A disabled fieldset is unusable and un-clickable. The disabled […]