English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
The HTML <meter> element is used to display scalar values or fractional values within a known range.
Use the meter element to display the given data range:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Basic Tutorial Website(oldtoolbag.com)</title> </head> <body> <p>Heat the oven to <meter min="200" max="500" value="350">350 degrees</meter>.<br> <meter value="0.6">60%</meter> </p> </body> </html>Test and see ‹/›
IEFirefoxOperaChromeSafari
All mainstream browsers support the <meta> tag.
The <meter> tag defines a measurement. It is used only for measurements with known maximum and minimum values.
such as: disk usage, relevance of query results, etc.
Note: The <meter> cannot be used as a progress bar, progress bars <progress> tag.
Use notes: unless the value range is from 0 to1(closed interval), otherwise the min and max attributes must be defined to ensure that the value attribute is within the value range. In other words, the default min and max values are 0 and1.
The <meter> is an HTML5 new tag.
Attribute | Value | Description |
---|---|---|
formHTML5 | form_id | Specifies one or more forms that the <meter> element belongs to. |
highHTML5 | number | Specifies the range of values defined as high. |
lowHTML5 | number | Specifies the range of values defined as low. |
maxHTML5 | number | Specifies the maximum value of the range. |
minHTML5 | number | Specifies the minimum value of the range. |
optimumHTML5 | number | Specifies the optimal value of the measurement. |
valueHTML5 | number | Required. Specifies the current value of the measurement. |
The <meter> tag supports global attributes, see the complete attribute table HTML Global Attributes.
The <meter> tag supports all HTML Event Attributes.