The meter tag in HTML
- 24-07-2022
- Trung Minh
- 0 Comments
The meter tag identifies a scalar measurement in a known range, or represents a fraction as a measure.
The meter tag is not used to represent the process taking place (e.g. the number of % loaded) but it represents a fixed value that does not change for a short time. If you want to show progress, you should use the progress tag.
When should a meter tag be used? When you want to represent a fractional value, some % value such as used disk space/disk capacity, maximum number of points/points, etc.
Using
Example : Use the meter tag to showcase your skills in your CV.
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> </head> <body> <main> <h2>Kỹ Năng</h2> <div> <label>PHP: </label> <meter value="8" min="0" max="10">2 out of 10</meter> <br> <label>HTML/CSS: </label> <meter value="0.6">60%</meter> <br> <label>JS/JQUERY: </label> <meter value="0.5">60%</meter> <br> <label>ENGLISH: </label> <meter value="0.9">60%</meter> </div> </main> <footer> freetuts.net </footer> </body> </html>
Representing the meter tag instead of normal numbers makes the page much more alive, doesn't it?