HTML CSS examples for CSS Widget:Button
Style a button with :hover and :active
<!doctype html> <html> <head> <meta http-equiv="X-UA-Compatible" content="IE=Edge"> <title>Active Button</title> <style type="text/css"> .button {<!-- w ww . j a v a 2 s . com--> padding:5px 13px; border:2px solid Chartreuse; background-color:yellow; } .button:hover { background-color:blue; } .button:active { background-color:pink; color:WhiteSmoke; } .frame { padding:3em; } </style> </head> <body> <div class="frame"> <button class="button">I'm a Button</button> </div> </body> </html>