[whatwg] the cite element

On Jun 5, 2009, at 3:53 AM, Ian Hickson wrote:

> I don't really understand what problem this is solving.
>
> HTML4 actually defined <cite> more like what you describe above; we
> changed it to be a "title of work" element rather than a "citation"
> element because that's actually how people were using it.
>
> I don't think it makes sense to use the <cite> element to refer to  
> people,
> because typographically people aren't generally marked up anyway. I  
> don't
> really see how you'd use it to refer to untitled works.
>
> Thus, I don't really think it makes sense to make the change you  
> propose.

There are plenty of times when you want to mark up someone's name. For  
instance, if you're quoting someone in a testimonial, you may want the  
quote to appear in normal roman text, but the person's name who you  
are quoting to be in italic and right aligned:

"Best value for the money!"
           -- J. Random User

I might format this as:

<aside class="testimonial">
   <q>Best value for the money!</q>
   <cite>J. Random User</cite>
</aside>

aside.testimonial cite:before { content: "?" }
aside.testimonial cite { display: block; font-style: italic; text- 
align: right }

Here's an example of someone asking about this specific use case, of  
how to mark up a testimonial and its source:

http://stackoverflow.com/questions/758785/what-is-the-best-way-to-markup-a-testimonial-in-xhtml

(note that I don't believe the uses of <blockquote> mentioned here,  
including by me, are correct, as the citation actually refers to the  
quote rather than being part of it, but I think the use of <cite> is  
perfectly reasonable)

The Mozilla Style Guide also uses formatting for <cite> that I believe  
would be appropriate for citing either a work or a person:

http://www.mozilla.org/contribute/writing/markup#quotations

Of course, it's generally preferable to cite a work, rather than a  
person, as then the citation can be verified; if you just include a  
person's name, you have to assume that they mean "personal  
correspondence" which is unverifiable, or simply that the work is left  
unspecified and someone else will have to track it down. But people do  
write quotes and attribute the quotation to the person rather than the  
work, and as HTML is about marking up content and not about enforcing  
academic standards, I don't see why HTML5 should be adding this  
unenforceable restriction that doesn't seem to add much value.

I wonder if there is value in specifying the semantics of elements  
like <cite> in much detail, in cases where there is no way to  
automatically verify those semantics and there is no use case for  
machine processing of those semantics. It seems that whatever the  
definition of <cite> is, you're going to need to use a microformat or  
microdata or RDFa to actually provide semantics that are machine- 
readable, so the spec should be relatively loose and leave the precise  
semantics up to one of the more flexible systems for specifying  
semantics.

-- Brian Campbell

Received on Thursday, 9 July 2009 12:51:55 UTC