WHAT YOU WILL LEARN IN THIS CHAPTER:
This chapter examines the various properties that CSS provides to position elements in a document. Positioning can be thought of as layering, in that the various elements of a page can be layered on top of others and given specific places to appear in the browser's window.
Like floating elements, positioning offers some unique characteristics that allow behavior you might not always expect. This chapter begins the discussion of positioning with none other than the position property.
The position property is used to give elements different types of positioning. Positioning gives you the ability to dictate with precision where in a document you want an element to appear. You can choose whether an element appears relative to a container element, or relative to the browser window. You can layer elements one on top of another.
The following table outlines the position property and its values, and the four offset properties, top, right, bottom, and left, and their possible values.
|position||static | relative | absolute | fixedInitial value: static ...|