CSS Class Selector
Structure
.classname
element1.classname
.classname1.classname2
Description
The class selector selects elements which have the class attribute with a specific value. To select a class, you add a . to the beginning of the class-name. Multiple class-values can be combined, although there are .compatibility problems in IE7. If there is no element-name before the class-selector, it will be applied to every element with the matching class-name.
Examples
Compatibility
Chrome | Firefox | Internet Explorer | Opera | Safari |
---|---|---|---|---|
Any | Any | Any | Any | Any |