[mod_python] StringField encoding?

Nick nick at dd.revealed.net
Sun Jun 19 12:53:53 EDT 2005


You could try explicity setting the media type in the content type to be 
ISO-8859-1 (or whatever character set you want to use) instead of unicode.

Nick

dharana wrote:
> Hello,
> 
> I have a form in one page. I send it with accented chars. Apache is 
> configured to send content as UTF-8 and browser is Firefox so I presume 
> Modpython gets utf-8 encoded data.
> 
> StringField inherits from str so, in this case, what kind of encoding 
> should I pressume it has? I'm having trouble trying to decode('utf-8') 
> the StringField instance, that's why I ask.


More information about the Mod_python mailing list