Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS grid problem with images.

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #45845

    Hey,

    I’ve using the grid that Chris wrote about on this site.

    its working fine but with one problem. I have 4 columns with a div element and with an image.

    all columns have a padding right except the last one.

    If you look at http://codepen.io/anon/pen/mtgAI

    the right div is bigger.

    the last column is now bigger. Any ways to get around this?

    Thank you :)

    #140409
    Alen
    Participant

    This is your issue:

    [class*=’col-‘]:last-of-type
    {
    padding-right: 0px;
    }

    #140471

    I know what the issue is, the module ive used is “.work”. Just wondering if there’s any way around this?

    #140478

    I’ve added
    [class*=’col-‘] {
    float: left;
    padding-right: 10px;
    padding-left: 10px;
    }

    and removed

    [class*=’col-‘]:last-of-type {
    padding-right: 0px;
    }

    which works :)

Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘CSS’ is closed to new topics and replies.