I\'m trying to display some pictures. All of them have the same width but different height. I\'m trying to do something like:
You can do this with no extra markup with CSS3 column-count
, assuming you at least have a single containing element.
Demo: http://jsfiddle.net/ThinkingStiff/NcxPr/
HTML:
CSS:
#container {
column-count: 3;
column-fill: balance;
column-gap: 10px;
width: 330px;
}
.image {
display: block;
margin-bottom: 10px;
width: 100px;
}
Output: