This link has been bookmarked by 389 people . It was first bookmarked on 01 Aug 2006, by someone privately.
-
13 Oct 15
-
22 May 14
-
14 Apr 14
-
07 Nov 13
-
28 Oct 13
-
21 Oct 13
-
03 Sep 13
-
11 Jun 13
-
25 Apr 13
-
15 Jan 13
-
01 Dec 12
-
10 Sep 12
-
28 Aug 12
-
02 Aug 12
-
21 Jul 12
-
04 Jun 12
-
02 Jun 12
-
09 May 12
-
01 Apr 12
-
13 Mar 12
-
12 Mar 12
-
03 Mar 12
-
21 Feb 12
-
11 Feb 12
-
06 Feb 12
-
The container div itself has no height, since it only contains floating elements.
-
-
03 Jan 12
-
26 Dec 11
-
14 Dec 11
-
08 Dec 11
-
23 Nov 11
-
03 Nov 11
-
24 Oct 11
-
28 Sep 11
-
27 Sep 11
Jochen FrommA common problem with float-based layouts is that the floats' container doesn't want to stretch up to accomodate the floats. If you want to add, say, a border around all floats (ie. a border around the container) you'll have to command the browsers someho
-
21 Sep 11
-
10 Sep 11
-
29 Aug 11
-
25 Jul 11
-
05 Jul 11
-
22 Jun 11
-
14 Jun 11
-
25 May 11
-
19 May 11
-
10 May 11
-
12 Apr 11
-
31 Mar 11
-
25 Mar 11
-
20 Mar 11
-
Mike Finneyshows a way to do this without adding an extra element with a clear both. For cases where you do not need a border, try it without the 100% width
-
If Explorer Mac is still important to you, use
overflow: hidden. -
complete
-
-
18 Mar 11
-
16 Mar 11
-
15 Mar 11
-
11 Mar 11
-
04 Mar 11
-
28 Jan 11
-
15 Jan 11
-
12 Jan 11
-
08 Dec 10
-
28 Nov 10
Jesse BrutonA common problem with float-based layouts is that the floats' container doesn't want to stretch up to accomodate the floats. If you want to add, say, a border around all floats (ie. a border around the container) you'll have to command the browsers somehow to stretch up the container all the way.
-
26 Nov 10
-
23 Nov 10
-
21 Nov 10
-
19 Nov 10
-
10 Nov 10
meinherzmachtbumA common problem with float-based layouts is that the floats' container doesn't want to stretch up to accomodate the floats. If you want to add, say, a border around all floats (ie. a border around the container) you'll have to command the browsers someho
-
09 Nov 10
-
20 Oct 10
-
08 Oct 10
-
04 Oct 10
-
10 Sep 10
-
03 Sep 10
-
02 Sep 10
Sean WinsteadScenario: DIV contains a 2 sub DIVs, one that floats left and one that floats right.
Shows how to make the containing DIV change its height to reflect sub DIV height. -
30 Aug 10
-
27 Aug 10
-
20 Aug 10
-
16 Aug 10
-
11 Aug 10
-
05 Aug 10
-
02 Aug 10
-
14 Jul 10
-
07 Jul 10
-
24 Jun 10
-
23 Jun 10
-
21 Jun 10
-
16 Jun 10
-
09 Jun 10
-
adding an HTML element for presentation's sake is something we've learned to avoid
-
overflow: auto;
-
- the height of the container remains flexible (ie. "as much as needed")
- the widths of the combined floats never exceed the width of the container, and preferably remain slightly smaller to allow for some flexibility
Of course some content might be hidden instead, but if we make very sure that
-
-
04 Jun 10
-
24 May 10
-
04 May 10
-
24 Apr 10
-
19 Apr 10
-
16 Apr 10
-
08 Apr 10
-
24 Mar 10
-
18 Mar 10
10base TomA common problem with float-based layouts is that the floats' container doesn't want to stretch up to accomodate the floats. If you want to add, say, a border around all floats (ie. a border around the container) you'll have to command the browsers somehow to stretch up the container all the way.
-
15 Mar 10
-
08 Mar 10
Page Comments
Would you like to comment?
Join Diigo for a free account, or sign in if you are already a member.