HTML CSS examples for CSS Widget:Hover to change Color
Ul li hover to change background color
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #nav1 ul li { display:inline; background-color:Chartreuse; padding:6px 6px 6px 6px; border-radius:6px 6px 0px 0px; } #nav1 ul li:hover { background-color:yellow; } </style> <!--from w w w. jav a 2 s.c om--> </head> <body> <div class="nav" id="nav1"> <ul> <li> <a href="#">Lore</a> </li> </ul> </div> </body> </html>