http://css-discuss.incutio.com/?page=ClassesVsIds The key thing to know is that IDs identify a specific element and therefore must be unique on the page - you can only use a specific ID once per document. Many browsers do not enforce this rule but it is a basic rule of HTML/XHTML and should be observed. Classes mark elements as members of a group and can be used multiple times, so if you want to define a style which will be applied to multiple elements you should use a class instead. Also, an element can have multiple class values (by space-separating the various values), while an ID must be a single value. In this way, a single element can "inherit" from multiple classes. The choice between ID and class can also be important from a SelectorSpecificity point of view, as IDs have higher specificity than classes. This means that, in situations where a class's properties might not be applied (for reasons of specificity and inheritance), an ID's properties probably will be -- IDs trump virtually everything, so you can be fairly sure that they'll make their mark. So when you're deciding whether to use class or id for your elements, consider this: is whatever property you're giving the element something that logically appear only once, or could it appear several times? In the former case, use id, in the latter, use class.
It is class if it uses it two or more times per page 1. If it is only one time, it is ID. When ID is used two or more times, it is likely to mis-operate in cgi.
Hi, Just to add a bit extra to what the guys said: you can also use multiple classes on a single element and one ID. To use multiple classes separate each class name with a single space, in the element's class attribute. - P
Spider, if you're using more than 2 pages - use classes! If you use only one page or only one thingy, use ID. ID = one person identity | Classes = more than 2 persons' identities