Apply CSS to li with group attribute - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:UL Element

Description

Apply CSS to li with group attribute

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
#divul ul>li[group="opt1"] {
   color:Chartreuse;
}
</style> <!--from   w ww  .  ja  v  a 2s  .  c  om-->
 </head> 
 <body> 
  <div id="divul"> 
   <ul> 
    <li group="opt1">Wake up</li> 
    <li>Go to sleep</li> 
   </ul> 
  </div>  
 </body>
</html>

Related Tutorials