[whatwg] several messages about <cite>

>>> If we go with something like a TYPE attribute, I hope we can give it a 
>>> better name. However, hiding semantics inside the value of an 
>>> attribute is a poor markup design in humble opinion. (Although it also 
>>> has some advantages.)
>>>       
>> It's subclassing: the general is sufficient, the specific better. Many 
>> markup languages use the design, and in this case, I think it's 
>> necessary.
>>     
>
> The class="" attribute can handle this case.
>
>   

I've seen a few suggestions now that class be used as an identifying 
attribute for purposes other than CSS. While this seems logical it 
raises some issues for designers and implementers. Consider the following:

<cite class="small book blue">The Neutronium Alchemist</cite>

In this example which of these classes is the type, and which serve only 
as style? A type or rel attribute is the better solution since it is 
generally understood to have a single value. <book> is an option but as 
others have pointed out it leads to potentially millions of new tags.

There is also the issue to consider that website "developers" and 
website "designers" are usually a totally different species. Designers 
often have little understanding of how classes may be used in an 
application. The potential is high that the designer will use 
class="book" on a totally unrelated element which is bound to cause 
visual problems if the application/developer is using the class as a 
program element.

My proposed solution is to use the rel attribute which basically serves 
this purpose already. It also has less potential for conflicts than  the 
type attribute since I have only ever seen rel used in the header 
whereas type has existing meaning for input fields and script tags.

<cite rel="book" class="small blue">The Neutronium Alchemist</cite>

Shannon

Received on Monday, 14 April 2008 20:48:33 UTC