I use a lot of JavaScript in SharePoint, but today I came across a problem that I do not understand. Every time I use accents in a script such as in an alert, it returns the following strange symbol: �.

enter image description here

Only I'm using jQuery and the mask as libraries. My library does not have anything if I put an alert ('hi') it returns the 'í' with symbol �.

enter image description here

1 Answer 1


I know this article is a bit old, but it might help. Replace your accented character with its octal value.

Alt-m   \355   ED   U+00ED   í   í  small i, acute accent

Else, please try to use UTF8. Add the following in <script type=... charset= ...> :


(source StackOverflow.SE)

  • I know this functionality, it's called ASCII table, but I can not use because it is dynamic, the user enters the warning, then have no way to use the ASCII table. And already used the charset, but it did not work.
    – Renanfdo
    Sep 10, 2014 at 13:07
  • the alert displays the ASCII characters Example: h&iacute;
    – Renanfdo
    Sep 10, 2014 at 13:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.