Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
HTML
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Character and entity references === {{See also|List of XML and HTML character entity references|Unicode and HTML}} As of version 4.0, HTML defines a set of 252 [[character entity reference]]s and a set of 1,114,050 [[numeric character reference]]s, both of which allow individual characters to be written via simple markup, rather than literally. A literal character and its markup counterpart are considered equivalent and are rendered identically. The ability to "[[escape character|escape]]" characters in this way allows for the characters <code><</code> and <code>&</code> (when written as <code>&lt;</code> and <code>&amp;</code>, respectively) to be interpreted as character data, rather than markup. For example, a literal <code><</code> normally indicates the start of a tag, and <code>&</code> normally indicates the start of a character entity reference or numeric character reference; writing it as <code>&amp;</code> or <code>&#x26;</code> or <code>&#38;</code> allows <code>&</code> to be included in the content of an element or in the value of an attribute. The double-quote character (<code>"</code>), when not used to quote an attribute value, must also be escaped as <code>&quot;</code> or <code>&#x22;</code> or <code>&#34;</code> when it appears within the attribute value itself. Equivalently, the single-quote character (<code>'</code>), when not used to quote an attribute value, must also be escaped as <code>&#x27;</code> or <code>&#39;</code> (or as <code>&apos;</code> in HTML5 or XHTML documents<ref>{{cite web|url=https://dev.w3.org/html5/html-author/charref|title=Character Entity Reference Chart|publisher=World Wide Web Consortium|date=October 24, 2012}}</ref><ref name="aposhtml">{{cite web|url=https://www.w3.org/TR/xhtml1/#C_16|title=The Named Character Reference '|publisher=World Wide Web Consortium|date=January 26, 2000}}</ref>) when it appears within the attribute value itself. If document authors overlook the need to escape such characters, some browsers can be very forgiving and try to use context to guess their intent. The result is still invalid markup, which makes the document less accessible to other browsers and to other [[user agent]]s that may try to parse the document for [[Web crawler|search and indexing]] purposes for example. Escaping also allows for characters that are not easily typed, or that are not available in the document's [[character encoding]], to be represented within the element and attribute content. For example, the acute-accented <code>e</code> (<code>é</code>), a character typically found only on Western European and South American keyboards, can be written in any HTML document as the entity reference <code>&eacute;</code> or as the numeric references <code>&#xE9;</code> or <code>&#233;</code>, using characters that are available on all keyboards and are supported in all character encodings. [[Unicode]] character encodings such as [[UTF-8]] are compatible with all modern browsers and allow direct access to almost all the characters of the world's writing systems.<ref>{{cite web|title=''The Unicode Standard'': A Technical Introduction |publisher=Unicode |url=https://www.unicode.org/standard/principles.html|access-date=2010-03-16}}</ref> {| class="wikitable" |+Example HTML Escape Sequences !Named !Decimal !Hexadecimal !Result !Description !Notes |- |{{Code|code=&}} |{{Code|code=&}} |{{Code|code=&}} |{{Code|code=&}} |[[Ampersand]] | |- |{{Code|code=<}} |{{Code|code=<}} |{{Code|code=<}} |{{Code|code=<}} |[[Less-than sign|Less Than]] | |- |{{Code|code=>}} |{{Code|code=>}} |{{Code|code=>}} |{{Code|code=>}} |[[Greater-than sign|Greater Than]] | |- |{{Code|code="}} |{{Code|code="}} |{{Code|code="}} |{{Code|code="}} |[[Double quote|Double Quote]] | |- |{{Code|code='}} |{{Code|code='}} |{{Code|code='}} |{{Code|code='}} |[[Single quote|Single Quote]] | |- |{{Code|code= }} |{{Code|code= }} |{{Code|code= }} |<code style="background-color: lightblue;"> </code> |[[Non-breaking space|Non-Breaking Space]] | |- |{{Code|code=©}} |{{Code|code=©}} |{{Code|code=©}} |{{Code|code=©}} |[[Copyright symbol|Copyright]] | |- |{{Code|code=®}} |{{Code|code=®}} |{{Code|code=®}} |{{Code|code=®}} |[[Registered trademark symbol|Registered Trademark]] | |- |{{Code|code=†}} |{{Code|code=†}} |{{Code|code=†}} |{{Code|code=†}} | [[Dagger (mark)|Dagger]] | |- |{{Code|code=‡}} |{{Code|code=‡}} |{{Code|code=‡}} |{{Code|code=‡}} | [[Dagger (mark)|Double dagger]] | Names are case-sensitive and may have synonyms. |- |{{Code|code=™}} |{{Code|code=™}} |{{Code|code=™}} |{{Code|code=™}} |[[Trademark symbol|Trademark]] | |}
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
HTML
(section)
Add topic