Encoders / DecodersLesson 15Free preview
HTML Entities
This lesson is part of Web Developer Tools · All levels
Summary
HTML Entities is a special code for displaying characters that if written directly could be considered part of a markup. For example, to display a sign smaller than and to display an ampersand. Entities can be names such as © or number codes such as ©. The use of entities is important when displaying code or user input to avoid damaging the structure of the page.
Key points
- Entity displays a special character without making it considered a markup
- < and > used to display square brackets
- & apos; must be used to display ampersand characters
- maintain spaces that lines should not be cut
- Use escaping when displaying user input to prevent security issues
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.