Page is a not externally linkable
- Code, Content, and Presentation
-- CSS
---- CSS Crib Sheet, cheatsheets, shortcut lists, syntax lists, & others


SuzyUK - 9:55 pm on Sep 16, 2004 (gmt 0)


Tips 'n' Tricks - part 8

5. Avoiding some pitfalls

- some of these are mentioned previously in this series of articles, but they're here for reference -

Case Sensitivity

Type selectors: div, h1, input etc.. are case-insensitive

Class and ID selectors: are case-sensitive.

e.g. BODY#myHomePage {}

will match <body id="myHomePage">

but it will not match <body id="myhomepage">

To avoid tracking case-sensitive issues perhaps it would advisable to always use lowercase for all selectors. This also fits with the XHTML coding practice which states that all attributes must be lowercase and quoted. So just adding to the good habit/coding practices if nothing else..


[end of Tips 'n' Tricks] - let me know if I missed any!

.... more Crib Sheet to follow...


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