From the course: CSS: Float-Based Page Layouts (2012)
Unlock the full course today
Join today to access over 22,700 courses taught by industry experts or purchase this course individually.
Controlling content overflow - CSS Tutorial
From the course: CSS: Float-Based Page Layouts (2012)
Controlling content overflow
We briefly came in contact with the overflow property during the chapter on floats. In this movie I want to discuss the overflow property in a little bit more detail and how it can help us when dealing with positioned elements. To do that, I have the overflow.htm file opened up and if I look through the code of this file, after a section where we talk about the overflow property a little bit, we have this section with a class name of container and it has a lot of text in it. If I preview this in a browser, you can see that right now the text is just forming the height of the section itself, so we don't have a defined height on this section. So because of that, the height is actually being determined by the content, so there really isn't any overflow going on at all. Now this is typical for your elements. If you don't declare a specific height, for example, the contents of the element forms the height. Now I want to go right back up here for just a minute and talk about the different…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
(Locked)
Relative positioning7m 59s
-
(Locked)
Absolute positioning8m 59s
-
(Locked)
Fixed positioning4m 23s
-
(Locked)
Controlling stacking order8m 31s
-
(Locked)
Clipping content8m 21s
-
(Locked)
Controlling content overflow5m 38s
-
(Locked)
Positioning elements: Lab3m 59s
-
(Locked)
Positioning elements: Solution3m 52s
-
(Locked)
-
-
-
-
-