Content deleted Content added
→Named character entities: HTML 4 (HTML 5 has more) |
|||
Line 37:
{{main|character entity reference}}
In HTML 4, there is a standard set of 252 named ''character entities'' for characters - some common, some obscure - that are either not found in certain character encodings or are markup sensitive in some contexts (for example angle brackets and quotation marks). Although any Unicode character can be referenced by its numeric code point, some HTML document authors prefer to use these named entities instead, where possible, as they are less cryptic and were better supported by early browsers.
Character entities can be included in an HTML document via the use of ''entity references'', which take the form '''<code>&</code>'''<var>EntityName</var>'''<code>;</code>''', where <var>EntityName</var> is the name of the entity. For example, <code>&mdash;</code>, much like <code>&#8212;</code> or <code>&#x2014;</code>, represents {{U+|2014}}: the [[em dash]] character "—" even if the character encoding used doesn't contain that character.
|