document.title = ("hello → goodbye");
This is not outputting the arrow: “→” as it should.
How does one escape that so it does?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You don’t need to escape it at all.
Just write
(and make sure your file is UTF8)
If you really want to escape it, you can use a Javsacript escape code:
"\u2192"Entities are only used in HTML source; you cannot use them in ordinary strings. (Except for
innerHTML, which is HTML source)