Grow your CSS skills. Land your dream job.

Solid colour best practise

  • # December 6, 2010 at 10:36 am

    Hi!!

    I’d like to use blocks of solid colour to use as spacers in my site. Would the best practise be

    1. Divs with background colour


     

    with css like


    .spacer-200
    {
    width:200px;
    height:10px;
    }

    .green
    {
    background-color:#0F0;
    }

    2. 1px (or some size) Images of set colour, ie:



    Or another method altogether?

    Thanks!

    Dave

    # December 6, 2010 at 1:13 pm

    If they are just spacers, you can simply add a bottom-border to the div, as opposed to adding a whole other div as a separator.

    # December 10, 2010 at 7:13 am

    Hiya, just realised I never replied. Thanks a lot buddy!!

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

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".