From the course: CSS: Enhancing Website Graphics

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Background image options

Background image options - CSS Tutorial

From the course: CSS: Enhancing Website Graphics

Start my 1-month free trial

Background image options

- [Instructor] In the last video, you created a background with the background image property. In this video, you will learn about other CSS properties that control the size, placement, and general appearance of that background image. But first, let's define what we mean by the word background. Every element is divided into three regions, the content-box, which contains the actual content of the element, such as any text or images, surrounded by the padding-box, which is the blank space around the element content, and finally, the border-box, which is the element's border. Okay, let's add a background to this element. By default, our background image is tiled so as to cover the entire element, from the border right down to the content, but we can change that with the background-clip property. Extending the background only though the content-box or through the padding-box, or, once again, up through the element's border. Let's change this to padding-box. The background image is tiled…

Contents