Jukka K. Korpela said:
I guess you're right, but let's try:
Both id and class attributes just attach some names to elements. The
difference is that id is like a proper name, very proper, in the sense
that you can attach it to one element only. And class is like a common
name, which you can attach to as many elements as you like.
Hmmm. In this case I think the explanation in the specs is actually better
than yours, unusual as this might be Jukka

Your explanation is by way of
metaphor, the spec is succinct.
After careful consideration I think both the spec and you may be slightly
wrong. There is this emphasis on the term "name". This is especially
confusing since "name" is an attribute itself, with a rather different
meaning.
Why don't we say just what the spec intends, or should have intended:
An id attribute is a unique identifier that may be given to an element. It
uniquely identifies the element. [add javascript/css/dom etc access to this
uniquely identified element here].
class is merely an attribute that does nothing except allow a style rule to
select an element that has a class attribute with a value of 'whatever'.
This may be reinforced by the fact that the class selector is introduced
rather late in chapter 5 of the CSS spec, as a shorthand way of selecting
[class~= whatever]
Cheers
Richard