js设置按钮的灰色不可点击
生活随笔
收集整理的這篇文章主要介紹了
js设置按钮的灰色不可点击
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
document.getElementById("btnSave").setAttribute("disabled", true);//設置不可點擊
document.getElementById("btnSave").style.backgroundColor ?= '#555555';//設置背景色
document.getElementById("btnSave").removeAttribute("disabled");//去掉不可點擊
window.parent.location.href = url;//調用父頁面重新加載
?
轉載于:https://www.cnblogs.com/wby-666/p/10255776.html
總結
以上是生活随笔為你收集整理的js设置按钮的灰色不可点击的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 消息中间件原理概念篇
- 下一篇: win10无法将设置应用到计算机,Win