html - css class inside first class selector -


i have following html code

<div class="span3">  <div class="abc">code fist div</div> <div class="abc">code second div</div>  </div> 

i need hide first division inside span3 division using external css. since have used span3 in other places too, have specify division class abc when selecting without saying first child division.

so how can select first abc division within span3 ?

you can achieve following style

div.span3 div.abc:first-child {    color: red;  }
<div class="span3">    <div class="abc">code first div</div>    <div class="abc">code second div</div>  </div>


Comments

Popular posts from this blog

user interface - how to replace an ongoing process of image capture from another process call over the same ImageLabel in python's GUI TKinter -

javascript - Using jquery append to add option values into a select element not working -

javascript - Restarting Supervisor and effect on FlaskSocketIO -