Thursday, June 21, 2012

HTML Entity Reference for Common Characters

HTML Entity Reference for Common Characters


HTML Entity Reference for Common Characters

Posted: 21 Jun 2012 07:22 AM PDT

HTML Entity Reference for Common StuffThere are lots of references online where you can quickly search and find the necessary HTML code for embedding all sorts of symbols and characters into your web pages.

I find that most of the references I’ve seen are far too exhaustive. So for my own personal use, I put together a chart of the character entity references that I’ve needed the most.

Obviously, what consitutes “common” would vary from developer to developer, but I hope this list covers most of the most commonly used symbols and characters.

Name Character Entity Numeric
Copyright © © ©
Registered ® ® ®
Trademark ™ ™
Curly Open Double Quote “ “
Curly Closed Double Quote ” ”
Curly Open Single Quote ‘ ‘
Curly Closed Single Quote ’ ’
Big Bullet/Dot • •
Small Bullet/Dot · · ·
Square Dot ⋅ ⋅
En Dash – –
Em Dash — —
Cents ¢ ¢ ¢
Pound (Currency) £ £ £
Euro (Currency) € €
Not Equal To ≠ ≠
Half (Fraction) ½ ½ ½
Quarter (Fraction) ¼ ¼ ¼
Three-Quarters (Fraction) ¾ ¾ ¾
Degrees ° ° °
Left Arrow ← ←
Right Arrow → →
Up Arrow ↑ ↑
Down Arrow ↓ ↓
Lowercase “e”, Grave Accent è è è
Lowercase “e”, Acute Accent é é é
Lowercase “c”, Cedilla ç ç ç
Ellipse … …
Triangle Down (none) ▼
Triangle Up (none) ▲
Triangle Left (none) ◀
Triangle Right (none) ▶
Name Character Entity Numeric

Final Notes

In HTML5, as far as I understand, you could technically just copy and paste the character right into your document and it will validate just fine. This is different from XHTML validation, which requires that you use the named or numeric entity reference to validate. Of course, if you’re concerned about how these characters are handled when entered into a database or form, then you might want to check out this article on Smashing Magazine, along with the comments.

Also, for the most part, pretty much any symbol can be found with a quick Google search. But like I said, many of the references are often too comprehensive and contain a lot of extra stuff that I don’t need.

Finally, when deciding what is “common”, keep in mind that I didn’t include any symbol that has its own key on most keyboards (e.g. “%” or “@”). Comment if you feel I’ve left out anything that qualifies as “common”. I know there are some accented characters that I’ve left out, so I’m considering doing a separate post that will have a chart of common foreign language characters. Maybe I’ll do that post mañana.

Related posts:

  1. CSS/HTML Tools and Resources Worth Checking Out
  2. Linking to jQuery: Always Reference a Specific Version
  3. CSS Terms and Definitions


No comments:

Post a Comment

Search This Blog

Top WordPress Seller