Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Move to the next row?

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #145073
    braadd
    Participant

    Hi,

    I know when content get to long it can move to the next line but how do I make it move to the next row.

    So if I only want 5 boxes going down my page and then it moves to the next row like this. (the boxes will be different)

    1 5 4
    4 6 0
    3 1 8
    5 9 6
    8 4 8

    So like that so instead of the page height getting bigger it will be the width.

    Thanks Brad

    #145112
    Martin Duran
    Participant

    Is this information being fed from a database? If not, then you’ll have an idea of how wide you need the div to be. So, start by wrapping your inline content in a div. Set a height to the parent div to prevent your content from exceeding one line, if that is what you are trying to prevent. Then, set a width, most likley exceeding the width of the body, or the parent div, to the div you’ve just created. Adjust your div’s width according to it’s content to see your content stretch horizontally, rather than vertically.

    #145220
    braadd
    Participant

    I see but the only thing with that is that if I have 12 split between 3 collumns it will put 4 but I want it to contantly have 4 rows no matter if there are 9 and it is better to have 3 rows and I want to have unlimited collumns as the content will be coming from a database.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.