I know that CSS only supports left and right values for the float property, but is there a technique to implement a floating top? I will try to explain. I have the following code:
<div style="float:left">
<div style="float:left">
<div style="float:left">
....
With this code every div is floated to left until the right limit of the page is reached. I want to do the same thing but vertically, so that every div is placed at the bottom of the previous one and then, when the bottom limit of the page is reached, a new column is created. Is there a way to do this using only CSS (and maybe editing the HTML code)?
Simply use vertical-align
:
.className {
display: inline-block;
vertical-align: top;
}