Javascript DOM HTML Meter high Property set

Introduction

Change the value of the high attribute in a gauge:

document.getElementById("myMeter").high = "60";

Click the button to change the value of the high attribute of the gauge.

View in separate window

<!DOCTYPE html>
<html>
<body>

<p>My scale: <meter id="myMeter" min="0" low="40" high="95" max="100" value="65"></meter></p>

<button onclick="myFunction()">Test</button>
<p id="demo"></p>

<script>
function myFunction() {/*from  ww  w.  j  ava 2s . c  om*/
  document.getElementById("myMeter").high = "60";
  document.getElementById("demo").innerHTML = "The value of the high attribute was changed.";
}
</script>

</body>
</html>

The high property sets or gets the value of the high attribute in a gauge.

The high attribute sets the range where the gauge's value is considered to be a high value.

This value must be less than the max attribute value, and greater than the low and min attribute values.

The high property accepts and returns a number type value.




PreviousNext

Related