CSS Beginners Do's and Dont's

Discussion in 'Web Development and Programming' started by FullMetalBabe, Aug 16, 2009.

  1. FullMetalBabe

    FullMetalBabe Zealot

    Joined:
    May 30, 2009
    Messages:
    2,912
    Likes Received:
    339
    Well since today this morning I've been going around online looking for new things to learn to implement on my designs. Luckily, I was in twitter and found an account that had posted some sites with tutorials on JQuery and CSS.

    I found this neat little website which had a LOT of great information, specially an 'Advice' section for CSS beginners with two great posts!

    I thought I'd share;
    http://www.sohtanaka.com/web-design/css-beginners-dos-and-donts-part-1/
    http://www.sohtanaka.com/web-design/css-beginners-do’s-and-dont’s-part-2/

    The website information on CSS and JQuery tips and Tricks is amazing and very interesting. I've spent the whole day reading! I can't do anything else anyways xD
     
    3 people like this.
  2. David

    David Regular Member

    Joined:
    May 30, 2003
    Messages:
    1,088
    Likes Received:
    133
    Location:
    Australia
    I wonder how many of these rules I break every day?
     
  3. Webmist

    Webmist Champion

    Joined:
    Jan 30, 2008
    Messages:
    305
    Likes Received:
    18
    Location:
    US
    First Name:
    Jen
    Me too. Probably some they don't even list.
     
  4. FullMetalBabe

    FullMetalBabe Zealot

    Joined:
    May 30, 2009
    Messages:
    2,912
    Likes Received:
    339
    Haha, I know I break a lot of those rules, I'm a rebel anyways!

    But I'm starting to dive in coding a template a little more and clean my CSS.
     
  5. David

    David Regular Member

    Joined:
    May 30, 2003
    Messages:
    1,088
    Likes Received:
    133
    Location:
    Australia
    So i just read these "articles" and the first one only had one actual tip in it to do cross browser checks.... :frown:

    The second article however, all the tips were actually tips regarding CSS :devil:
     
  6. Dan

    Dan Future Proof

    Joined:
    Jul 16, 2009
    Messages:
    368
    Likes Received:
    84
    Location:
    Staffordshire
    First Name:
    Dan
    ** bookmarked **
     
  7. ArnyVee

    ArnyVee Regular Member

    Joined:
    May 25, 2009
    Messages:
    1,264
    Likes Received:
    39
  8. Demo

    Demo Regular Member

    Joined:
    Jun 9, 2009
    Messages:
    172
    Likes Received:
    6
    Location:
    Europe
    First Name:
    Demo
    Nice, hadn't heard about CSS sprites yet
     
  9. FullMetalBabe

    FullMetalBabe Zealot

    Joined:
    May 30, 2009
    Messages:
    2,912
    Likes Received:
    339
    Man! I would watch it if I could. But my connection is the crappiest E V E R !
     
  10. Wayne Luke

    Wayne Luke Regular Member

    Joined:
    Apr 2, 2009
    Messages:
    991
    Likes Received:
    276
    Very basic articles in my opinion. Though I guess they are for the very very beginning before you even know what CSS is really.

    However I have to disagree with the classes and ID tip. This one:
    It just needs to be reworked some. First Classes and IDs are not interchangeable as they suggest. They represent two different types of selectors with different functions.

    IDs are for sectioning your site (header, footer, sidebar, article, comments, etc...). There should only be one of each ID per page. Shouldn't be hard to misuse since only one element of each of these should be on the page. e.g. <h1 id="pagetitle">

    Classes are for styling your site and they are designed to be overloaded. Some of the best CSS techniques comes from overloading CSS classes. I'll agree they don't need to be on every element but they shouldn't be relegated to containers either. Their example should talk about this and give proper examples of overloading if they truly want to provide worthwhile content.

    So I am not saying you need a class on every element but imagine their example with a class="current" on their sidebar navigation. A great way to provide visual clues to end users.
     
  11. Soliloquy

    Soliloquy Regular Member

    Joined:
    Jun 3, 2009
    Messages:
    2,402
    Likes Received:
    66
    Location:
    New York City
    I always looked at "overloading classes" as preparing for the future. What if six months from now you realize you need to emphasize a particular area of your web page? If there's already a class in the HTML, all you have to do is add a new definition in the stylesheet. If not, you have to go in and add the class to your markup on every page. (Mind you, I wouldn't make a class for every little list element. But definitely every list.)
     

Share This Page