HTML Working Group T. Berners-Lee
INTERNET-DRAFT MIT/W3C
Some text. *wow*
|
\-"Some text. "
|
\-EM
| |
| \-
| |
| \-"*wow*"
| |
| \-
|
\-This is a Heading
Some elements only have a start-tag without an end-tag. For
example, to create a line break, you use the `
' tag.
Additionally, the end tags of some other elements, such as
Paragraph (`
', `', and `' are equivalent, whereas `&' is different from `&'. In a start-tag, the element name must immediately follow the tag open delimiter `<'. 2.2.4. Attributes In a start-tag, white space and attributes are allowed between the element name and the closing delimiter. An attribute typically consists of an attribute name, an equal sign, and a value, though some attributes may be just a value. White space is allowed around the equal sign. The value of the attribute may be either: * A string literal, delimited by single quotes or double quotes and not containing any occurrences of the delimiting character. NOTE - Some historical implementations consider any occurrence of the `>' character to signal the end of a tag. For compatibility with such implementations, when `>' appears in an attribute value, it should be represented with a numeric character reference. For example, `' should be written `' or `'. * A name token (a sequence of letters, digits, periods, or hyphens). NOTE - Some historical implementations allow any character except space or `>' in a name token. In this example, is the element name, src is the attribute name, and `http://host/dir/file.gif' is the attribute value: A useful technique for computing an attribute value literal for a given string is to replace each quote and space character by an entity reference or numeric character reference as follows: ENTITY NUMERIC CHARACTER REFERENCE CHAR REF CHARACTER DESCRIPTION TAB Tab LF Line Feed CR Carriage Return Space " " " Quotation mark & & & Ampersand For example: Note that the SGML declaration in section 13.3 limits the length of an attribute value to 1024 characters. Attributes such as ISMAP and COMPACT may be written using a minimized syntax. The markup:can be written using a minimized syntax:
NOTE - Some historical implementations only understand the minimized syntax. 2.2.5. Comments To include comments in an HTML document, use a comment declaration. A comment declaration consists of `'. Each comment starts with `--' and includes all text up to and including the next occurrence of `--'. In a comment declaration, white space is allowed after each comment, but not before the first comment. The entire comment declaration is ignored. NOTE - Some historical HTML implementations incorrectly consider any `>' character to be the termination of a comment. For example:
HTML Comment Example 2.2.6. Example HTML Document
Structural Example First Header
This is a paragraph in the example HTML file. Keep in mind that the title does not appear in the document text, but that the header (defined by H1) does.
- First item in an ordered list.
- Second item in an ordered list.
- Note that lists can be nested;
- Whitespace may be used to assist in reading the HTML source.
- Third item in an ordered list.
This is an additional paragraph. Technically, end tags are not required for paragraphs, although they are allowed. You can include character highlighting in a paragraph. This sentence of the paragraph is emphasized. Note that the </P> end tag has been omitted.
Be sure to read these bold instructions. 3. HTML as an Internet Media Type An HTML user agent allows users to interact with resources which have HTML representations. At a minimum, it must allow users to examine and navigate the content of HTML level 1 documents. HTML user agents should be able to preserve all formatting distinctions represented in an HTML document, and be able to simultaneously present resources referred to by IMG elements (they may ignore some formatting distinctions or IMG resources at the request of the user). Conforming HTML user agents should support form entry and submission. 3.1. text/html media type This specification defines the Internet Media Type[IMEDIA] (formerly referred to as the Content Type[MIME]) called `text/html'. The following is to be registered with [IANA]. Media Type name text Media subtype name html Required parameters none Optional parameters level, charset Encoding considerations any encoding is allowed Security considerations see 3.3, "Security Considerations" The optional parameters are defined as follows: Level The level parameter specifies the feature set used in the document. The level is an integer number, implying that any features of same or lower level may be present in the document. Level 1 is all features defined in this specification except those that require the