Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p><a href="http://www.w3.org/TR/html4/intro/sgmltut.html#h-3.2.1" rel="nofollow noreferrer">HTML allows to omit certain start and/or end tags</a>:</p> <blockquote> <p>Some HTML element types allow authors to omit end tags (e.g., the <code>P</code> and <code>LI</code> element types). A few element types also allow the start tags to be omitted; for example, <code>HEAD</code> and <code>BODY</code>. The HTML DTD indicates for each element type whether the start tag and end tag are required.</p> </blockquote> <p>If you examine a document type definition like the one of <a href="http://www.w3.org/TR/html4/sgml/dtd.html" rel="nofollow noreferrer">HTML 4.01</a>, the elements are declared with the <a href="http://www.is-thought.co.uk/book/sgml-5.htm#ELEMENT" rel="nofollow noreferrer">element declarations <code>&lt;!ELEMENT … &gt;</code></a>. And within such an element declarations, two characters specify whether the start or end tag of an element can be omitted. See the <a href="http://www.w3.org/TR/html4/struct/text.html#edef-P" rel="nofollow noreferrer">definition of <code>P</code></a> for example:</p> <pre><code>&lt;!ELEMENT P - O (%inline;)* -- paragraph --&gt; </code></pre> <p>Here the <code>-</code> after the element name <code>P</code> denotes that the start tag is required and the <code>O</code> denotes that the end tag may be omitted. Another example, the <a href="http://www.w3.org/TR/html4/struct/global.html#edef-HEAD" rel="nofollow noreferrer"><code>HEAD</code> element</a>:</p> <pre><code>&lt;!ELEMENT HEAD O O (%head.content;) +(%head.misc;) -- document head --&gt; </code></pre> <p>Here the two <code>O</code> specify that both the start and end tag can be omitted.</p> <p>Omitting both tags on elements is only possible as such elements are implicit in their context. In case of <code>HEAD</code>, the content model of the parent <a href="http://www.w3.org/TR/html4/struct/global.html#edef-HTML" rel="nofollow noreferrer">element <code>HTML</code></a> is specified as follows:</p> <pre><code>&lt;!ELEMENT HTML O O (%html.content;) -- document root element --&gt; </code></pre> <p>Where the parameter entity <em>html.content</em> is defined as follows:</p> <pre><code>&lt;!ENTITY % html.content "HEAD, BODY"&gt; </code></pre> <p>That means the content model of <code>HTML</code> is implicitly defined as <code>HEAD</code> followed by <code>BODY</code>.</p> <p>You can take a look at the <a href="http://www.w3.org/TR/html4/index/elements.html" rel="nofollow noreferrer">index of HTML 4.01 elements</a> to see what tags of what elements can be omitted.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload