0

Hi guys new to bootstrap and need some help with the column re ordering. I've read the documentation on the bootstrap site regarding the push and pull classes but I have problems understanding it. So any help will be appreciated thanks!

Desktop

`[Image1][text1][Image2][text2]`

`[image3][text3][image4][text4]`

Tablet

`[image1][image2]
 [text1][text2]
 [image3][image4]
 [text3][text4]`

Mobile

`[image1]
 [text1]
 [image2]
 [text2]
 [image3]
 [text3]
 [image4]
 [text4]`

JSFIDDLE: https://jsfiddle.net/DTcHh/16908/

Junda
  • 1
  • 2
  • I don't understand the question :) What exactly do you need? Tag me when you reply so I can see. – Ariel Weinberger Feb 12 '16 at 13:06
  • @Ariel Hey Ariel, sorry if my question wasn't clear enough. As stated above, i need the div 'text1' to be underneath 'image1' on tablet view instead of 'image2' being below 'image1'. Hope it's clear enough now and thanks! I'll post a image if need be to illustrate what i need if you need me to. – Junda Feb 12 '16 at 13:14
  • I think I understood you better. Can you show your code? Are you sure that you split the columns into rows properly? – Ariel Weinberger Feb 12 '16 at 13:16
  • @Ariel I've updated the OP with a jsfiddle link. Thanks in advance! – Junda Feb 12 '16 at 13:25
  • I have edited my answer. Please upvote and set as unswer if it was helpful! – Ariel Weinberger Feb 12 '16 at 13:41
  • @Ariel Hey sorry but i need 4 columns on desktop, 2 on tablet and 1 on mobile. prntscr.com/a2axq1 hopefully this helps to illustrate my problem – Junda Feb 12 '16 at 14:11

1 Answers1

-1

You are a bit unclear. The schemes that you provided in your question represent the responsiveness of Bootstrap.

For example, on tablet the rows will be split to provide better user experience in terms of responsiveness, or in simple words - no horizontal scrolling (as long as it depends on Bootstrap, and you don't make any additions that affect this concept).

If the screen is smaller, displaying the items normally will result in horizontal scrolling and this is what we are trying to avoid, so this is why it occurs.

Pulling and pushing

Pulling and pushing are ways to manipulate the grid, and push or pull (literally) the columns as if there were actual columns in there, while there are none.

I would recommend reading this question, the answer provided there is great.

Edit

For your question, you should split the columns into rows. So for example:

<div class="container">
    <div class="row">
        <div class="col-md-4">Col 1</div>
        <div class="col-md-4">Col 2</div>
        <div class="col-md-4">Col 3</div>
    </div>
    <div class="row">
        <div class="col-md-4">Col 4</div>
        <div class="col-md-4">Col 5</div>
        <div class="col-md-4">Col 6</div>
    </div>
</div>

Will show up like this:

[Col 1] [Col 2] [Col 3]
[Col 4] [Col 5] [Col 6]

And on mobile, like this:

[Col 1]
[Col 2]
[Col 3]
[Col 4]
[Col 5]
[Col 6]
Community
  • 1
  • 1
Ariel Weinberger
  • 2,195
  • 4
  • 23
  • 49
  • Hey sorry but i need 4 columns on desktop, 2 on tablet and 1 on mobile. http://prntscr.com/a2axq1 hopefully this helps to illustrate my problem – Junda Feb 12 '16 at 14:04