|
Posted by John Hosking on 05/15/07 18:40
Francesco Moi wrote:
> I want to place 5 divs within the same row:
> div-div-div-div-div
> <div class="fooclass"><img src="image.jpg"></div>
> <div class="fooclass"><img src="image.jpg"></div>
> <div class="fooclass"><img src="image.jpg"></div>
> <div class="fooclass"><img src="image.jpg"></div>
> <div class="fooclass"><img src="image.jpg"></div>
> <div class="fooclass"><img src="image.jpg"></div>
> div.fooclass
> {
> float:left;
> background-color:red;
display:inline;
/*presumably you have some padding and margins, too*/
> }
> However, the divs are really floating, and I went them to fill their
> row, because I have to insert <br/> to fill this row.
It won't always be five, but might be three or six, depending on the
width of the container (viewport). But that's what you really want,
isn't it?
HTH
--
John
Navigation:
[Reply to this message]
|