Optional end-tags: The two cells in the table below should be displayed identically; the left cell uses end tags (or "net-enabled" start tags for empty elements, which are needed in XHTML), the right cell leaves off the end tags for the elements which declare the end tags optional. All elements on both sides are declared with a minimum of attributes.
Line Breaks ![]() Paragraph One Paragraph Two
Options in a select Table sub-elements (left column will be 100 pixels, and right column will be 200 pixels if the COL and COLGROUP elements are accepted):
|
Line Breaks ![]() Paragraph One Paragraph Two
Options in a select Table sub-elements (left column will be 100 pixels, and right column will be 200 pixels if the COL and COLGROUP elements are accepted):
|
These are the examples used by the specification:
The entity source should only be visible inside the parentheses; the character displayed in the
"Character Reference" column should either be displayed similarly to the reference image
(small differences in font face or size are okay) or replaced by an "unknown character" glyph, which
is often simply a question mark.
Character description | Character Reference | Reference Image |
---|---|---|
Ampersand (&) | & | ![]() |
Less Than (<) | < | ![]() |
Greater Than (>) | > | ![]() |
Quote (") | " | ![]() |
Lower case A with Circle (å) | å | ![]() |
Cyrillic Capital Letter I (И) | И | ![]() |
Kanji for Water (水) | 水 | ![]() |
There should not be any yellow cells in the table below with text. If there is text in the table below, it will explain how the browser has mishandled the comment. If the text in a cell does not start with "Browser", the output may be a side effect of another error.
Browser incorrectly treats "<!-->" as empty comment. --> |
Browser incorrectly treats "<!--->" as empty comment. --> |
From the specification:
SGML (see [ISO8879], section 7.6.1) specifies that a line break immediately following a start tag must be ignored, as must a line break immediately before an end tag. This applies to all HTML elements without exception.
Therefore, there should only be one line of preformatted text below, even though there is a line break after the start tag for the bold text and one before the end tag.
This is one line of preformatted text. This is bold text, still on line one. This is after the bold text, but should still be line one.
It is rare for browsers to support the SGML constructs below, so I will be impressed if someone can tell me of a browser that supports all of them correctly (mauvecloud at mauvecloud dot net (mailto link avoided to discourage spam generators))
There is a CDATA section between the curly braces on the next line: The line above should look like one of the two lines below, but the spec does not make it entirely clear which is correct. Two SGML page break tags are below, but according to section 4.2,
Therefore, if there is anything other than the normal amount of space between the quote about it,
your browser is not dealing with the processing instructions correctly.
Inspired by a page called "Dark Side of the HTML" (author unknown), which had
once been at http://www.best.com/~sem/dark_side/index.html (gone now), but this
document uses a DOCTYPE tag, unlike the pages there (which makes lack of
support for the SGML tricks uncertain).
If shorthand markup is supported, the two right columns of the table below will
be identical, and the text will look as described.
{ <
{<This> <<is> <<<the> <<<<contents> <<<<</of> <<<<<<the> <<<<<<<CDATA> <<<<<<<<section.>}
{}
B.3.6 Processing Instructions
User agents must not render SGML processing instructions (e.g., <?full volume>) or comments.
B.3.7 Shorthand Markup
Shorthand Tested Shorthand Tags Normal Tags
Net Tag This is an h3 element.
Empty Start Tag
Empty End Tag Normal Text Bold Text> Normal Text
Normal Text Bold Text Normal Text
Closed Start Tag Normal Text Bold Italic Text Normal Text
Normal Text Bold Italic Text Normal Text