| Author |
CSS: referencing other definitions
|
Mike Firkser
Ranch Hand
Joined: Oct 21, 2003
Posts: 243
|
|
I've been looking high and low, and have been unable to find an answer to this. I've heard that in a css you can define a style by referring to another, for instance, you define something like this: and if you want to then define another element, to be basically the same (for instance, you want it bold) you can refer to this, so if in the future you want to change it slightly (like the color) it is no problem. Is it also possible to do it with redefining tags--so if you want text in a <td> and a <p> to be the same, it is no problem. Thanks in advance.
|
Mike Firkser
Rutgers '84
|
 |
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15003
|
|
I am guessing you mean something like this:
|
 |
Mike Firkser
Ranch Hand
Joined: Oct 21, 2003
Posts: 243
|
|
Not really. Maybe this will be a better example: As most of the standard text in a page is in a table and/or a paragraph, I may want them to be the same. What I want to do is redefine the <p> and <td> tags. Is there a way to redefine the <p> tag (setting font style, etc), and in the redefinition of the <td> tag can I refer to the <p> tag so the font will be the same (in case I forget to put text in a table inside a <p> tag). This way, if I want to change the font from TimesNewRoman to Verdana, I just have to change the <p> tag. Thanks.
|
 |
 |
|
|
subject: CSS: referencing other definitions
|
|
|