Summary 2

Stylin' with CSS Chapter 1


Nested tags

When nesting tags, you must close them in stack order- first open last closed. The tags that have been nested become the children or descendants to the outer tag and tag becomes the parent or ancestor to the tags in it. All enclosing tags can be nested.


Block and in line

Most HTML elements have a display property of either a line or a block. Heading and paragraphs are block elements meaning they stack on top of each other, the block extends the width of the page. Images and links are line elements meaning there width is dependent on the content and they will continue on the same line.


Document object model

The Document object model or the DOM is created by the HTML structure. From which a family tree relation ship between elements is formed. Which consists of parent- relationship with tag(s) immediately nested, children- relationship with tag immediately above (nested in) them, siblings- relationship with tags on the same leave of nesting, descendants- any tag nested, and ancestors- any tag with nesters.