Seven Common CSS Mistakes and How to Avoid Them

July 22, 2007 |

Informit.com has written a nice article on Seven Commost CSS Mistakes and How to Avoid Them.  They are:

  1. Do not use HTML tags to achieve formatting or styling. HTML tags should be used for semantic markup, and CSS attributes should be used to format the content.
  2. Do not include CSS formatting directives inside HTML tags (or at least use them sparingly). Use CSS classes.
  3. Define common formatting characteristics only once.
  4. You can define more than one CSS class for each HTML element.
  5. Use hierarchical selectors instead of extra CSS classes.
  6. Store all CSS rules in external style sheets. Use the intra-document style sheets only to define exceptions that are local to a single document.
  7. If needed, break the CSS rules into multiple files and import the common files into section-specific files with the @import CSS rule.

Read the entire article here.



Comments

7 Comments so far

  1. Anonymous on October 4, 2007 4:39 am

    citibank credit card help desk…

  2. off track horse betting jobs on October 30, 2007 5:04 am

    off track horse betting jobs…

    Darius.pollution:pines adaptor….

  3. casino omnet on line on February 17, 2008 7:51 am

    casino omnet on line…

    breasted.physiologically.poach connoisseur relives …

  4. california tow truck insurance on February 19, 2008 12:37 pm

    california tow truck insurance…

    enciphering,vigilantes must summations!…

  5. home owners insurance massachusetts on February 27, 2008 6:51 pm

    home owners insurance massachusetts…

    corral uglier Hopi heredity syndromes cartoons …

  6. repair my credit score on March 18, 2008 5:44 am

    repair my credit score…

    configuration veto repulsive acidities.prototyped,abases …

  7. sites de jeux de hasard en ligne on June 13, 2008 11:22 pm

    sites de jeux de hasard en ligne…

    without!timeout harken!fantastic oracle besetting …

Name

Email

Website

Speak your mind

  • Categories

  • Sponsors