croakingtoad
11-18-2003, 03:29 AM
Is it possible to 'nest' css elements using the <div> tag?
For example, say I want every instance of anchor statements <a> within a specific <div> class to apply a certain style to them?
IE:
<div class="special">
<a href="foo.html">Foo</a>
<a href="oof.html">Oof</a>
</div>
So, I have declared a style for the <div> and is it possible within the stylesheet to associate styles for the <a> tags without having to specify them using the class statement? Of course, all other tags within the document (outside the <div>) would maintain their normal state. Somewhat like the :first-child pseudo-element...?
Thanks in advance!
For example, say I want every instance of anchor statements <a> within a specific <div> class to apply a certain style to them?
IE:
<div class="special">
<a href="foo.html">Foo</a>
<a href="oof.html">Oof</a>
</div>
So, I have declared a style for the <div> and is it possible within the stylesheet to associate styles for the <a> tags without having to specify them using the class statement? Of course, all other tags within the document (outside the <div>) would maintain their normal state. Somewhat like the :first-child pseudo-element...?
Thanks in advance!
