<html>
<body>
点数:<input type="range" id="myRange" step="10">
<p>单击该按钮可显示滑块控件的 step 属性值。</p>
<button onclick="myFunction()">试一试</button>
<p><b>注意:</b>IE 9 及更早版本不支持带有 type="range" 的输入元素。</p>
<p id="demo"></p>
<script>
function myFunction() {
var x = document.getElementById("myRange").step;
document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>