W3C home > Mailing lists > Public > www-style@w3.org > August 2005

Re: [CSS21] Additional Note

From: Malcolm Rowe <malcolm-www-style@farside.org.uk>
Date: Fri, 26 Aug 2005 10:55:07 +0100
To: www-style@w3.org
Message-ID: <20050826095507.GB5413@lorenz.farside.org.uk>

On Fri, Aug 26, 2005 at 09:03:28AM +1000, Lynn Alford wrote:
> >Note: If an element has multiple class attributes, their values must be
> >concatenated
> >with spaces between the values before searching for the class. As of
> >this time
> >the working group is not aware of any manner in which this situation can
> >be reached,
> >however, so this behaviour is explicitly non-normative in this
> >specification.
> >
> >Please reconsider this note because multiple attributes of the same name
> >are not allowed in either XML or SGML.
> Perhaps this note is about
> <para class="important title sidebar"> where I have three separate styles 
> available in the style sheet.  I believe that such use would be valid XML 
> as well.

No, it's about a situation where an element in the document has multiple
attributes that are recognised as 'class' attributes by CSS. (CSS doesn't
define what determines a 'class' -- or 'id' -- attribute, but leaves that up
to the document language(s)).

Actually, there is a way you can get this now, if we permit XHTML2 attributes
on XHTML elements:

<html xmlns="http://www.w3.org/1999/xhtml"
    <title>Virtual Library</title>
    <p class="foo" xh2:class="bar">This paragraph has classes 'foo' and

Assuming that it's valid for an XHTML1/XHTML2 UA to interpret the XHTML2
attributes on the above XHTML1 document -- something that's far from clear
anyway -- then all the original paragraph is saying is that a CSS-compliant
processor must apply class selectors as if the class definition was
something like <p class="foo bar">.

Received on Friday, 26 August 2005 09:55:11 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:20 UTC