HTML CSS examples for CSS Widget:Div Table
Style div table by nth-of-type(1) and :last-of-type
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .container {<!--from ww w . j a v a2 s .c om--> width:901px; height:221px; } div .image { width:100px; height:100px; background:Chartreuse; display:inline-block; } div .image:nth-of-type(1) { min-width:206px; min-height:206px; float:left; margin-right:6px; } div .image:last-of-type { background:yellow; color:blue; } </style> </head> <body> <div class="container"> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> <div class="image"></div> </div> </body> </html>