Welcome to WebmasterWorld Guest from

Forum Moderators: not2easy

Message Too Old, No Replies

Making horizontal boxes



4:45 pm on Nov 7, 2012 (gmt 0)

System: The following 2 messages were cut out of thread at: http://www.webmasterworld.com/html/4510047.htm [webmasterworld.com] by bill - 3:09 pm on Nov 8, 2012 (jst +9)

I want to have 3 boxes aligned horizontal with css.

Do I have to make a float left and float right box first, and in one of the floats put again a floatleft and float right?


is it possible to have 3 divs aligned in such way that they are aligned next to each other?

A tip or start is helpful :-)


10:11 pm on Nov 7, 2012 (gmt 0)

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month

Doing it with floats is one way: left, right and default. Another way is to make three divs set to {display: inline-block} with a specified width, and pack all three inside a single bigger block.

The widths have to add up to less than 100% even if you've ruthlessly cut out all margins, padding and borders. Don't ask me why; I just know what doesn't work.

Make sure you think about what will happen if the viewport isn't wide enough to hold all three of your boxes with their content.

Featured Threads

Hot Threads This Week

Hot Threads This Month