Shirley Harshenin wrote:
> Hi!
> 
> I am working on a page that has both light and dark backgrounds
> therefore need two different colors for links (dark color link for
> light bg, light color link for dark bg). HOW do I code that? I've
> tried creating a new style (in CSS) but the main content style
> over-rides it. :(    

Hi Shirley

You will need to use the cascade to identify the elements you want to
target. For example:

[html]
<div id="lightback">light background <a href="#">link</a></div>
<div id="darkback">dark background <a href="#">link</a></div>

[css]
/* backgrounds */
div#lightback { background-color: #fff; }
div#darkback { background-color: #000; }
/* links */
#lightback a { color: #000; }
#darkback a { color: #fff; }


Regards

Scott Swabey
Design & Development Director - Lafinboy Productions
www.lafinboy.com | www.thought-after.com



______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to