|
Posted by bcr07548 on 10/08/05 21:28
I was validating some CSS last night and kept getting warnings that my
TD styles had a 'background-color' but no 'color.' I didn't have one
because I wanted the text to be the color specified in the page's style
sheet. I thought that was the idea of CSS - styles "cascade" down and
any property not found for a particular tag at that level are then
searched for at higher levels of the DOM structure.
Anyway, for the sake of having the CSS validate without warnings, I
want to add color properties for the tags that need them. But for sake
of maintainability, can you set one CSS property equal to another so
you don't have to hunt down all the properties and change their values?
For example,
body
{
background-color: #000088;
color: #0000FF;
}
td
{
background-color: #000044;
color: body.color;
}
This is sort of what I am after but I haven't found any info on it
online and have no idea what the syntax would be, if it is even
possible. I've seen this asked in newsgroups (including this one) but
no one ever seems to answer the question. Does anyone know if this can
be done?
-Brandon
Navigation:
[Reply to this message]
|