I want to select all P's which do not follow a H3 or a P so:
<img>
<p> this is selected</p>
<p> this is not</p>
<p> this is not</p>
<span>
<p> this is selected</p>
<h3>
<p> this is not</p>
I tried
p + :not(h3, p) and :not(h3, p) + p
but they do not work
what is the solution? Please help
` and `
` elements into `` tags and then apply a class to them. This way you can target elements before and after the block.
– matsko Nov 03 '12 at 19:59