Page is a not externally linkable
- Code, Content, and Presentation
-- CSS
---- My CSS does not work when I convert from ID to CLASS


Fotiman - 2:05 pm on Nov 28, 2012 (gmt 0)



OK, you can make an exemption for "left" "right" "center" and similar because, well, it would be silly otherwise.

No, those are all silly. Don't use class names that describe the presentation, use names that describe the content. That way, if you ever decide that you want to change the presentation (for example, maybe you want it to be on the right instead of the left), you only need to modify the presentation layer (the CSS) and not the content layer (the HTML markup).


Thread source:: http://www.webmasterworld.com/css/4523063.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com