HTML CSS examples for CSS Property:background-color
Change content of div with background color slowly via color transition
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #results {<!--from w w w . ja va 2s .c o m--> background: #dddada; color: 000000; cursor: pointer; transition: color 1s ease; transition: background 1s ease; } #results:hover { background: red; color: black; } </style> </head> <body> <div id="results"> test data </div> </body> </html>