Consider the structure displayed in Figure 14-2. This tree has more branches
than the tree diagram in Figure 14-1 because the first paragraph has a child of
its own, the italic element:
<body>
<p>I cannot <i>emphasize</i> this point enough!</p>
<p>But in this paragraph, I’m calmer.</p>
</body>
Figure 14-2 is a tree diagram of the preceding code:
In the diagram in Figure 14-2, the body is the parent of the two paragraphs,
but the body is only the ancestorof the italics element. The paragraphs are
children of the body. The italics element is the child of its parent paragraph,
and also the ancestor of the body. Class dismissed.
When a root sits above the tree ......................................................
Above the <body>is the HTML, the rootof the structure, as they call it.
And the <head> and <body>elements come next in the tree. To help you
visualize this, here’s a complete Web page. Figure 14-3 is its diagram:
<html>
<head>
<style>
</style>
</head>
<body>
<body>
<p>
<i>
<p>
Figure 14-2:
This
diagram
contains an
ancestor
descendant
relationship
— between
the
and the
.