0

I want to create an article that will start in left column, and when it reaches bottom it goes to right column to continue, something like this:

enter image description here

So I want the text to continue on the second column when it reaches the bottom, any ideas how I can do this?
If it's pure CSS I would be very happy, I couldn't find the answers because search engine won't search for the right thing.

TylerH
  • 20,799
  • 66
  • 75
  • 101
nikagar4
  • 830
  • 4
  • 11
  • 23
  • 1
    You should check this post : http://stackoverflow.com/questions/9305198/transfer-overflow-from-one-div-to-another – Amaury Hanser Nov 04 '16 at 19:04
  • Here is another one: http://stackoverflow.com/questions/3009670/flow-2-columns-of-text-automatically-with-css – Cave Johnson Nov 04 '16 at 19:07
  • Using google would have been enough. –  Nov 04 '16 at 19:10
  • 1
    Unless you MUST do this, you may want to rethink your design. Having columns is a great idea for the printed page, because the size of the medium is fixed. The medium of the web is variable and as such, you may run into problems when trying to translate this onto different devices. Also, it's poorly supported. – Armstrongest Nov 04 '16 at 19:53

3 Answers3

2

Try this:-

#col {
-moz-column-count: 2;
-webkit-column-count: 2;
column-count: 2;
}
<div id="col">Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum</div>
CSS
Razia sultana
  • 2,168
  • 3
  • 15
  • 20
1

Use the columns property.
Note that browser compatibility is limited (from IE11, including).
http://caniuse.com/#feat=multicolumn

.columned-content {
   -webkit-columns: 300px 2;
   -moz-columns: 300px 2;
   columns: 300px 2;
}

Syntax:
columns: <column-width> || <column-count>;

More info - https://css-tricks.com/almanac/properties/c/columns/

George Kagan
  • 5,913
  • 8
  • 46
  • 50
1

You can use column-count along with plenty other options. Take a look here css column count

Stuart
  • 6,630
  • 2
  • 24
  • 40