[Gambas-user] Converting a POST string

Benoît Minisini gambas at ...1...
Fri Jul 19 18:49:04 CEST 2013


Le 19/07/2013 18:27, Rolf-Werner Eilert a écrit :
>
>
> Am 19.07.2013 18:02, schrieb Benoît Minisini:
>> Le 19/07/2013 17:43, Rolf-Werner Eilert a écrit :
>>> Hi,
>>>
>>> just bounced into this: When doing a POST request on a web form, the
>>> string input by the user is encoded in UTF-8 but as %high-byte%lowbyte
>>> such as "%C3%BC" for "ü".
>>>
>>> How do I reconvert these worms to UTF-8 strings? Tried conv(), but
>>> didn't succeed yet. Is there a quick way, or do I have to pick out all %
>>> and convert them one-by-one?
>>>
>>> Thanks for your help.
>>>
>>> Rolf
>>>
>>
>> One by one. Or fix your HTTP client!
>>
>
> Err - you mean the server? Apache configuration?
>

If bytes are swapped in the client request, then the client is buggy. 
UTF-8 is low byte first.

-- 
Benoît Minisini




More information about the User mailing list