Using the wildcard attribute selector in CSS - HTML CSS CSS Selector

HTML CSS examples for CSS Selector:attribute value ends with

Description

Using the wildcard attribute selector in CSS

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">
li[data-widget-type$="color"] {
   color:Chartreuse;
}
</style> <!--from  w  w w . j av a2s . co m-->
 </head> 
 <body> 
  <ul> 
   <li>Lorem </li> 
   <li data-widget-type="red.color">Lorem </li> 
   <li data-widget-type="none.color">Lorem </li> 
  </ul>  
 </body>
</html>

Related Tutorials