Reputation: 2924
I need to support Spanish language for a website which I am developing. I have created an XML file which contains the english text and corresponding Spanish text. I am reading this XML file on user's choice (language dropbox). Everything is working fine unless there are some spanish characters which browser is not able to display properly.
The content of XML file is:
<Spanish>
<title></title>
<loginBoxHeader1>Login Panel -</loginBoxHeader1>
<loginBoxHeader2>Por favor, proporcione las credenciales siguientes!</loginBoxHeader2>
<username>Nombre de Usuario:</username>
<password>Contraseña:</password>
<LoginBtn>iniciar la sesión</LoginBtn>
<RememberCheckbox>Recordar mi usuario en este equipo</RememberCheckbox>
</Spanish>
characters ñ
and ó
are not visible in browser. I set encoding of XML file to ISO-8859-1. Also I added following meta tag in HTML page:
<meta http-equiv="Content-Type" content="text/html; charset=ISO 8859-1">
I also tried with UTF-8 encoding but problem persists. Any thoughts?
Thanks.
Upvotes: 3
Views: 6398
Reputation: 65
As @pawlakppp mentioned, have you checked the Encoding of your xml file. Try this -
Upvotes: 0
Reputation: 11
have you tried google fonts? http://www.google.com/fonts Click on "New to Google Fonts?" and follow the steps. I picked 1, just "Normal 400", followed the steps. I had the same problem, my spanish characters would show up as black diamonds with question marks on them.
Upvotes: 1
Reputation: 1302
Your page is decoded with utf-8 (but should in iso...), the reason can be:
Or go other way and save xml in utf-8 using for example notepad++
Upvotes: 0
Reputation: 2870
Maybe the fonttype doesn't support the special characters? I have had the same problem before and it was just becuase the font didn't have the symbols in it. Changed the font and problem solved.
Upvotes: 0