- From: (unknown charset) John Lewis <gleemax@hotpop.com>
- Date: Thu, 25 Nov 1999 15:11:37 -0600
- To: (unknown charset) <www-style@w3.org>
I'm not quite sure I understand your problem, but I have a possible solution: /* site.css */ globalproperties { font-family: helvetica,sans-serif; } <html> <head> <title>Hello World</title> <link rel="stylesheet" type="text/css" href="site.css"> <style type="text/css"> @import url(site.css) /* import the rules defined in site.css */ globalproperties { color: red; } /* and append the local declarations to the selector */ </style> </head> <body> <table> <tr> <td class="globalproperties">This is now RED and ARIAL!</td> </tr> </table> </body> </html> ----- Original Message ----- From: <pdf@bizfon.com> To: <www-style@w3.org> Sent: Tuesday, July 25, 2000 1:37 PM Subject: Giving a class the same values as another class : : : Is it possible (or are there any plans to make it possible) to include the : properties of one class inside the properties of another? For example, suppose : I have a page that is part of a site. There are certain site wide properties : that I may assign through a class (for example, if I want certain items : throughout the site to use a particular font). But there are also properties : that are specific to that page that I don't want to be given to the entire site. : Those properties would be defined in a class that was local to that page only. : You can't declare something as having multiple classes (not that I know of : anyway), so it would be nice to be able to do something like this: : : /* site.css */ : /* This is a global style, used throughout the site */ : globalproperties { font-family: helvetica,sans-serif; } : : : : <html> : <head> : <title>Hello World</title> : <link rel="stylesheet" type="text/css" href="site.css"> : <style type="text/css"> : /* This is my local style, used on this page only */ : /* Would be nice to INCLUDE global class in my local class like so */ : localproperties { color: red; classname: globalproperties; } : </style> : </head> : <body> : <table> : <tr> : <td class="localproperties">This is now RED and ARIAL!</td> : </tr> : </table> : </body> : </html> : : : : This is a very simplified example, but I think it gets my question across. I : haven't seen any way to do something like this. Is it possible? Will it be : possible in the future? : Thanks, : Peter Foti
Received on Tuesday, 25 July 2000 16:12:00 UTC