0

I have two questions.

I have got a problem when I have an h2 before a p. I tried this :

h2 + p {
margin-top: 0
}
p + h2 {
margin-bottom: 0 
}

But when I have many h2 + p in the same page. The first h2 + p elements are not stylized. Its strange.

Then, how to stylize a <p><strong>my text</strong></p> before an <ul> ?

ul + p > strong {
margin-top: 0
}

That's don't work :-/

Thank you in advance for your help.

Xroad
  • 415
  • 1
  • 7
  • 24
  • 3
    Possible duplicate of [Is there a previous sibling selector?](http://stackoverflow.com/questions/1817792/is-there-a-previous-sibling-selector) – Vucko Nov 19 '15 at 22:05
  • If you show us the **actual** structure we might be able to help. At the moment we have no way of finding out wht your selector is not working. – Paulie_D Nov 20 '15 at 10:10

0 Answers0