Open In App

HTML | DOM Meter low Property

Last Updated : 23 Aug, 2022
Improve
Improve
Like Article
Like
Save
Share
Report

The DOM Meter low Property is used to set or return the value of the low attribute in a gauge. The low attribute is used to specify the range where the value of gauge is considered to be low. The value of the low attribute must be greater than the “min”, less than the “max” and “high” attribute. 

Syntax: 

  • It returns the low property.
meterObject.low
  • It is used to set the low property.
meterObject.low = number

Return Values: It returns a numeric value, that represents a floating point number that is considered to be a low value.

Property Values: It contains a value i.e number which specify the floating point number that is considered to be a low value. 

Examples-1: This Example returns the low property

HTML




<!DOCTYPE html>
<html>
<head>
    <title>
      DOM Meter low Property
      </title>
</head>
<body>
    <h1>GeeksforGeeks</h1>
    <h2>DOM Meter low Property:</h2>
    <!-- assigning id to meter with
        properties. -->
    <meter value="0.6"
           max="0.9"
           min="0.1"
           id="GFG"
           optimum="0.6"
           high="0.5"
           low="0.2">
      </meter>
    <br>
    <br>
    <button onclick="Geeks()">
        Submit
    </button>
    <p id="sudo"
       style="font-size:25px;
              color:green;">
      </p>
    <script>
        function Geeks() {
 
            // return meter low property
            var g =
                document.getElementById("GFG").low;
            document.getElementById("sudo").innerHTML =
              g;
        }
    </script>
</body>
</html>


Output: 

Before Clicking On Button:

  

After Clicking On Button:

  

Example-2: This Example sets the low Property

HTML




<!DOCTYPE html>
<html>
<head>
    <title>
      DOM Meter low Property
      </title>
</head>
<body>
    <h1>
      GeeksforGeeks
      </h1>
    <h2>
      DOM Meter low Property:
      </h2>
    <!-- assigning id to meter with
        properties. -->
    <meter value="0.6"
           max="0.9"
           min="0.1"
           id="GFG"
           optimum="0.6"
           high="0.5"
           low="0.2">
      </meter>
    <br>
    <br>
    <button onclick="Geeks()">
        Submit
    </button>
    <p id="sudo"
       style="font-size:25px;
              color:green;">
      </p>
    <script>
        function Geeks() {
 
            // set meter low property
            var g =
                document.getElementById("GFG").low =
                "0.4";
           
            document.getElementById("sudo").innerHTML =
              "The value of the low attribute was changed to "
            + g;
        }
    </script>
</body>
</html>


Output : 

Before Clicking On Button:

  

After Clicking On Button:

  

Supported Browsers: The browser supported by DOM Meter low Property are listed below:

  • Chrome 6
  • Edge 18
  • Firefox 16
  • Safari 6.0
  • Opera 11


Like Article
Suggest improvement
Previous
Next
Share your thoughts in the comments

Similar Reads