I came across with this problem.
When I send to the server via $.get() [So far, the $.post() and $.ajax() have been used to send form with post data] a little amount of data [2 or 3 var=val pairs] with some special chars, such as ñ, í, ó [Common in my language] I get at the server side strange characters instead, such as "
ñ
" instead the ñ.
I've reading about and realized that is because of the use of the XmlHttpRequest Object which uses UTF-8
encoding. All of the encodings are UTF-8, browser, .html, php headers and so.
I tried also with "escaping" the specific param with encodeURIComponent() but no luck; keep getting the
strange chars when I make an echo($_GET["var"]).
So does anybody knows if the jQuery AJAX functions do that job ?? If yes, what is going wrong ??
If not, how can I achieve it ??
Any help would be appreciated.
Thanks to all !!