>Well, I'm afraid this is not really a solution. encodeURIComponent is  
>the way to go!

I know. But escape() is a quick solution for my problems till someone could 
give me another one ;)
Selfhtml says: "encodeURICompontent will replace escape() in future"


>This is exactly what should be sent to the server. It's your _server_  
>code that should be changed (so it uses UTF-8 decoding for the  
>params), not anything on the client side.

Hm...i don't know if my server_code is the reason for my problems. I'm using 
PHP...maybe I need to use utf8_decode()...i will try

>I don't understand what you mean by that. The server should clearly  
>receive "test%C3%A4" (as this is what gets passed to setData). What/ 
>how exactly did you check with firebug?

It's the "POST-Param" I checked in firebug. 
Check the details(params, post, headers, response) of the sent url in the 
firebug-console. Under the "POST"-tab there are all sent Post-Parameters and 
Values. That's where I saw "testä". Could this really be a server-side-problem?

Tobias

-----Ursprüngliche Nachricht-----
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Andreas Junghans
Gesendet: Freitag, 16. März 2007 15:36
An: qooxdoo Development
Betreff: Re: [qooxdoo-devel] Umlaute in Post-Request

Hi Tobias,

Am 16.03.2007 um 14:03 schrieb Tobias Koller (GERMO GmbH):

> When I use escape() instead of encodeURIComponent or encodeURI then  
> it works!

Well, I'm afraid this is not really a solution. encodeURIComponent is  
the way to go!

The problem is that escape() only deals with 1-byte characters. This  
works with European languages (as long as the server and the client  
have the same idea about the encoding that is used, usually  
ISO-8859-1). However, it breaks badly with more complex charsets like  
Japanese. The only long-term solution that works with all languages  
is to use UTF-8 (which encodeURIComponent does).

> param is set to "testä".
>
> the alert shows me: "test%C3%A4"

This is exactly what should be sent to the server. It's your _server_  
code that should be changed (so it uses UTF-8 decoding for the  
params), not anything on the client side.

> But the request-param is "testä". I checked it with firebug.

I don't understand what you mean by that. The server should clearly  
receive "test%C3%A4" (as this is what gets passed to setData). What/ 
how exactly did you check with firebug?

> The js-File is saved as UTF-8.

This is irrelevant as there are no non-ASCII characters in your code  
snippet (only in user input).

Regards,

   Andreas


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to