Quantcast
Channel: :not(:first-child) and :not(:first-of-type) not working - Stack Overflow
Browsing latest articles
Browse All 3 View Live

Answer by HiLuLiT for :not(:first-child) and :not(:first-of-type) not working

As Edd above me suggested, they are not siblings - so you need to change your selector to the parent (.someContainer).But I'd also suggest another approach, the "positive" approach - set the first...

View Article



Answer by Edward for :not(:first-child) and :not(:first-of-type) not working

That's because they are not siblings.If you change the :not selector to the parent div, it will work..someContainer:not(:first-of-type){ margin-top: 50px;}#someDivID{ width:...

View Article

:not(:first-child) and :not(:first-of-type) not working

I have sort of a tree system. What I'm trying to do is give all the parents a margin except for the first one. This is my HTML:<div id="someDivID"><div class="theBody"><div...

View Article
Browsing latest articles
Browse All 3 View Live




Latest Images