CSS selectors and combinations of tags -
i have sequences of
tags such this
<div id="info"> <h1>some title</h1> <p>some content</p> <h1>some title</h1> <p>some content</p> <h1>some title</h1> <p>some content</p> </div>
i need image separator after each
tag, not after last one
i have following css styles defined:
#info { margin-left:245px; width: 545px; } #info h1{ color:#000; font-size:24px; font-weight:100; } #info p{ color:#6c6f70; font-size:22px; } #info p:last-child :after{ content: ""; } #info h1+p:after{ content: " " url(../img/dotseparator.png); padding-top:25px; display:block; height:8px; }
but separator after last paragraph... can please me wrong in styles? thanks!
try this
#info h1+p:not(last-of-type):after{ content: " " url(../img/dotseparator.png); padding-top:25px; display:block; height:8px; }
Comments
Post a Comment