Forums

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

Home Forums CSS nested columns Re: nested columns

#126499
shamai
Member

interesting paulie. you do it differently.
you are not suppose to take off padding from last-of-type when you want padding on the outside. instead you use something like:

what chris does:
.grid-pad{
padding: 20px 0 20px 20px;
}

notice the 0? thats where the last column has a padding so its not needed.
thats how I do it.

padding ends up on outside like this: [ and the last side is filled by the inner last cols padding making them perfectly equal in size and aligned too.

yours is different…. your columns are not equal. the one with paddings is significantly losing real estate compared to its brother column

dont look at the width of the columns, look at the width of the columns minus the padding