The Lodge is members-only design/dev videos and Office Hours.

Next Office Hours Session: "Implementing an SVG Icon System" Nov 30 - 6:00 PM Eastern

[Solved] Whats the difference on this CSS?

  • # March 12, 2010 at 7:52 am

    Hi everyone! I have a simple question. Can someone explain the difference between these two style sheets?

    In every theme in wordpress i have found this structure:

    but in this theme wordpress, i found this structure:

    # March 12, 2010 at 10:05 am

    its just personal preference really

    I like the top way of writing it, because its more readable :)

    # March 12, 2010 at 10:16 am

    Thanks, but I think that the second method is less effective, right?

    # March 12, 2010 at 10:45 am

    Nope, simply just personal preference.

    Some people even do a combination of the two (grouping like-objects on a single line):

    .class {
    width: 123px; height: 123px;
    margin: 0; padding: 0 12px 0 0;
    background: url(image.jpg) no-repeat; color: #ffffff;

    At the end of the day, it’s personal preference, in my opinion.

    # March 12, 2010 at 10:57 am

    Ok! Many thanks for the answer! :)

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed