You need to declare the encoding of your site (or scripts).
You can use <meta charset="UTF-8">in HEADyour site to indicate that the entire page will be UTF-8encoded. -
OR
If you just need your script to encode. You can encode JUST script - IE<script type="text/javascript" charset="utf-8" src="blah.js"/>
In any case, you should always indicate your site / script the character set that you use.
source
share