Forum Moderators: not2easy
In another html doc for the same site I want to say
<div id="admin-forms">
<h2>My admin form</h2>
<h4>My section</h4>
</div>
I don't want to have to apply a style to each individual element I just want to apply different styling rules deepending on the containing div
Now in my css I want to be able to style h1,h2,h3,h3 with something like
#public-forms, h1, h2, h3, h4 {
background-color: #ffffc0;
}
#admin-forms, h1, h2, h3, h4 {
background-color: #efe;
}
So that all h1 to h4 elements that appear inside a div are given a specific background colour.
Now what I am doing above does colour the background for the h elements but they all have the same colour applied.
i.e. all h1 elements take on the background colour for the admin forms selector.
Any pointers as to how I should be doing this would be greratly appreciated.
Thanks
James