W3C home > Mailing lists > Public > www-html@w3.org > July 2005

Re: Proposal: Allow Support for Multiple External Style Sheets with Limited Scope

From: Sebastian Redl <sebastian.redl@getdesigned.at>
Date: Thu, 07 Jul 2005 18:11:42 +0200
Message-ID: <42CD543E.2030205@getdesigned.at>
To: www-html@w3.org


> I propose “markup support” for a new styling property that would allow
> embedded and inline style attributes the ability to call upon an
> external style sheet that’s scope is the same as if the styling
> properties were embedded or inlined in the markup.
>
> For example, if I imagined this property, it would be called
> "stylelink" and it would work like this:
>
> <div style="stylelink:url(http://www.LonnieBest.com/style.css)">
>
> <p>I want all elements inside this div tag to be influenced by the
> external style sheet specified in the stylelink property above, but I
> don't want any other elements outside this div tag to be influenced at
> all by that external style sheet specified in the stylelink property.
>
> </p>
>
> </div>
>

Hi,

I don't know how active the www-style mailing list is, but since you are
proposing a CSS property, that's where this should really go.

Second, is there any particular part about this that cannot be solved by
the use of a class attribute?

<div class="completelyforeign">
<p>Inside the tag.</p>
</div>

And in your "external stylesheet", you simply prefix every selector with
.completelyforeign. This will cause these selectors to apply to the tags
inside the div with increased specifity, while the tags outside are
completely unharmed.
Then you could group all these styles in a single sheet, thus reducing
the number of separate HTTP requests.

Sebastian Redl
Received on Thursday, 7 July 2005 16:11:08 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:16:03 GMT