Element Positioning [6/15]
Positioning helps you to arrange elements on your page and do it precisely and with flexibility. Positioning is used to create complex "multi-layer" interfaces, for instance, pop-up windows or galleries, and design small decorative elements.
The main property responsible for positioning is
position: it switches between different element positioning modes. Four more properties are:
left; they define where exactly the element will be positioned. And, last but not least, the
z-index property: it controls the order of layers on your page.
In this task, you will change the mode of element positioning from standard to absolute, and move the element around the page a little.
In more detail, we will tackle the theory and practice of element positioning in the upcoming "Positioning" course.
Enable absolute positioning for one of the paragraphs.
- Add to the CSS rule for the
- Then, add property
left: 100px;to the same class
- and property
The properties we have used here are discussed in more detail in the upcoming "Positioning" course.