HTML SYMBOL

Maha



HTML Symbol

Certain characters in HTML have unique meanings and are challenging to enter on a keyboard by themselves. They're referred to as symbols a lot. For instance, standard keyboards only have the dollar symbol; they do not include the rupee or euro currency symbols. HTML, however, offers additional methods for adding these symbols to webpages. 

How can symbols be added to an HTML document

Entities are used to add symbols to an HTML document. We may utilize the entity number, which is a decimal or hexadecimal reference, in the absence of an entity name. A text string that starts with an ampersand (&) and ends with a semicolon (;) is called an HTML entity. They are used to represent characters and symbols that are not readily available on keyboards for usage on web pages, or those are reserved in HTML.

Types of two Entities

HTML entities come in two types: named entities and numeric entities. When referring to a character or symbol, the Named entities employ a descriptive term, such as © for the copyright symbol. Characters are referred to by numbers in numerical entities.

Example:


  <!DOCTYPE html>
  <html>
  <head>
   <title> HTML Symbols</title>
  </head>
  <body>
     <h1>Common HTML Symbols</h1>
     <p>Trademark Symbol : &trade; </p>
     <p>Copyright Symbol : &copy; </p>
     <p>Left Arrow Symbol : &larr; </p>
  </body>
  </html>


Output:






More topic in HTML

Our website uses cookies to enhance your experience. Learn More
Accept !

GocourseAI

close
send