Posts

Showing posts with the label CSS in combinators

CSS in combinators

Image
    combinators in CSS   1. Descendant selector   Descendant selector (space) matches all the elements that are descendants of a specified elements, it means that selectors can select element that are descendants of others selector. The element does not have  be  direct child, but rather  descendant down the line. Syntax : element1 element2 { style_properties } Descendant selector   Example   <!DOCTYPE html> <html> <head> <style>  ol li {  color: red;  }   </style> </head>  <body> <ol> <li>Databases</li> <br> <ul> <li>Oracle/PLSQL</li>  <li> SQL </li> </ul> <li> ASP.Net </li> <li> Java </li> </ol> </ul>  </body>  </html>