<html>
<body>
<input type="range" id="myRange"><br><br>
<button onclick="disableBtn()">禁用滑块控件</button>
<button onclick="undisableBtn()">启用滑块控件</button>
<script>
function disableBtn() {
document.getElementById("myRange").disabled = true;
}
function undisableBtn() {
document.getElementById("myRange").disabled = false;
}
</script>
</body>
</html>