Solving Conflicts with Escape Characters

As you may have discovered, HTML specifies that certain characters are “reserved” or serve a special purpose for browsers. The most obvious conflicts are the greater-than and less-than characters (<, >), since these identify tags to browsers in HTML. Any character that may be accidentally interpreted as HTML by the browser should be replaced with its escape code equivalent.

There are also characters that have no easy “keyboard” equivalent, (such as the copyright symbol - © ) in which case an escape code must be used.

Question:

So what is a developer to do if they need to write some math (or something else less stressful than including comparison operators in their page)?

Answer:

Use special codes, known as escape characters, that the browser can use to render the intended character!

This is not a fun process, but one that is necessary since HTML is a language.

Also, for those of you who are more “security-minded” or wanting to protect yourself and your client from “middle-man attacks,” using escape characters is critical, as evidence by some discussions around the web.