Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Vertical-floating elements in CSS?

Is there any solution for my problem, described in this image?

http://i.imgur.com/6uhxlNm.png

I have a DIV-tag with a fixed height. In this element, i have a List. This List should be floated like columns. The list-elements have a fixed width. if there are "too much" elements in the Div-Tag, it should scroll horizontally. The amount of columns and elements is not fix. It should also work in old Browsers.

Is there any solution with HTML/CSS?

like image 603
andi Avatar asked Jan 14 '23 18:01

andi


1 Answers

You can use columns and related CSS3 properties:

Here is fiddle: http://jsfiddle.net/DeLL7/5/

Updated for for non-fixed number of columns and fixed container height. However, for older browsers, you're probably out of luck, without having to "manually" arrange the boxes.

like image 200
Floremin Avatar answered Jan 19 '23 12:01

Floremin