HTML entity characters

Source: Internet
Author: User
Tags html header

Some characters, like (<), are of special significance to HTML, so these characters are not allowed in the text. To display (<) this character in HTML, we must use the entity character.

Entity characters

There are some characters that are special to HTML, like less than symbols (<), which are used to define HTML header tags. If we want to display such characters in the browser, we must insert the entity characters in the HTML code.

An entity character has three parts: a (&) symbol, a special symbol name or a # plus a special number, and finally a semicolon (;).

To display less than the symbol is written in HTML:< or < the advantage of using a name is that it is easier to remember than to use numbers.

but not all browsers support the latest entity characters, Not as good as the entity characters are supported by all browsers.

Note entity characters need to be case-sensitive. This example is for you to experiment with these entity characters (only ie browser)

No line breaks

The most common entity character in HTML is the No line break interval.

General HTML will give you the text to remove the interval, if you have 10 spacing in the text, then the HTML will remove 9 of them. To add an interval, you have to use the    character.

Some very common entity characters:

results description entity name entity number   
 , Non-newline interval &nbsp & #160
< Less than &lt & #60
> Greater than &gt & #62
& "&" &amp & #38
" double quotes &quot & #34
Single quotation marks &apos; IE does not support & #39



Other characters commonly used character entities:


results



Span style= "font-family: the song Body;" >



entity name



Number of entities


< Span style= "font-family: the song Body;" >&cent;



&cent
& #162

< Span style= "font-family: the song Body;" >&pound;


lb


&pound
< Span style= "FONT-SIZE:12PT;" >& #163

< Span style= "font-family: the song Body;" >&yen;


meta


&yen

< Span style= "color: #000000;" >& #165

< Span style= "font-family: the song Body;" >§


Department


&NBSP;

  &sect
& #167

< Span style= "FONT-SIZE:10.5PT;" >&copy;


copyright


&copy

& #169

< Span style= "FONT-SIZE:10.5PT;" >&reg;


registered trademarks


&reg

< Span style= "FONT-SIZE:12PT;" >& #174
   x

multiply


&times

& #215

< Span style= "font-family: the song Body;" >÷


except


&divide


& #247

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.