0
Button color javascript
I use o mouse down to change color button with document.getElementById(“demo”).style.background = “red”; But how I get back it’s original default color with onmouseup?
1 Odpowiedź
+ 5
use css.
#demo:active{
background: red;
}
this way, it'll back to original color