Chapter 6. The Fundamental Objects

When a document displays on a user’s screen, what shows up is not the underlying HTML code. Instead, it is the browser’s interpretation of that code. In the absence of any explicit instructions to the contrary, the browser displays the document using a set of default parameters. In HTML, for example, the browser puts P elements in separate blocks of text and LI elements in blocks with a label on the side, but it does not create a separate block for EM elements.

You can affect the basic shape of elements onscreen by using the display property. With this property, you can specify that each element be displayed onscreen as one of the following:

• A block of text – For example, paragraphs and headings are usually ...

Get Cascading Style Sheets: Designing for the Web, Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.