Answer the question
In order to leave comments, you need to log in
How to arrange content in multiple columns depending on page width?
There is a page made up on bootstrap. Holds tiles. These tiles should be arranged in several columns, so that the number of columns varies depending on the width of the page.
First I did this:
<div class="col-md-4 col-sm-4">
<div class="tile">...</div>
<div class="tile">...</div>
<div class="tile">...</div>
</div>
<div class="col-md-4 col-sm-4">
<div class="tile">...</div>
<div class="tile">...</div>
<div class="tile">...</div>
</div>
<div class="col-md-4 col-sm-4">
<div class="tile">...</div>
<div class="tile">...</div>
<div class="tile">...</div>
</div>
Answer the question
In order to leave comments, you need to log in
<div class="col-md-4 col-sm-6 col-xs-6">...</div>
somehow
jsfiddle.net/u9naX
As you wrote, using media queries will not work, you can only do this:
1 2 3
4 5 6
...
1 2
3 4
...
1
2
..
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question