The form attribute on a <meter> tag specifies the form the meter is associated with.
The value of this attribute is the id
of the form.
A <meter> element with a form attribute. The meter is outside the form, but associated with it.
<form action="/tutorial/action.html" id="project-form">
<fieldset>
<legend>Project Information</legend>
<input type="text" name="name" placeholder="Project name"><br /><br />
<input type="submit" value="Submit">
</fieldset>
</form> <br />
<div>Project completion: 80%</div>
<meter form="project-form"
value="0.8" name="completion">90%</meter>
Note: The meter value is not submitted during form submission.
The form attribute specifies the form the meter is associated with.
The attribute value is the id of the form.
The meter value is not included during form submission.
<meter form="form-id">
Value | Description |
---|---|
form-id | The id value of the form. |
Here is when form support started for each browser:
Chrome
|
Not Supported | |
Firefox
|
Not Supported | |
IE/Edge
|
Not Supported | |
Opera
|
Not Supported | |
Safari
|
Not Supported |
Back to <meter>