/

HTML / CSS / JavaScript Tutorial

HTML Standard attribute: high

[this page | pdf | back links]

The HTML high attribute indicates a range that is considered to constitute a high value for a <meter> element.

 

Valid attribute values (when used with <meter> elements) include:

 

Value

Description

number

(Floating point) number defining number above which value is deemed ‘high’. Should be lower than the max attribute and higher than the low attribute

 

EXAMPLE:


HTML USED IN THIS EXAMPLE:
<!DOCTYPE html>
<html> <!-- Copyright (c) Nematrian Limited 2018 -->
<head></head>
<body>
Input value: <input type="text" id="x1" value="30">
<button onclick="myClick()">Click button to set value</button><br><br>
Set using HTML:<br>
<meter id="x2" min="10" low="30" high="70" max="90" ></meter>

<br><br>Set using JavaScript:<br>
<meter id="x3"></meter>

<script>
document.getElementById("x3").setAttribute("min", "10");
document.getElementById("x3").setAttribute("low", "30");
document.getElementById("x3").setAttribute("high", "70");
document.getElementById("x3").setAttribute("max", "90");
function myClick() {
  var v = document.getElementById("x1").value;
  document.getElementById("x2").setAttribute("value", v);
  document.getElementById("x3").setAttribute("value", v);
}
</script>

</body>
</html>


NAVIGATION LINKS
Contents | Prev | Next | HTML Attributes


Desktop view | Switch to Mobile