Em Qua, 2006-07-12 às 11:06 +0100, Bruno Silva escreveu:
> I'm new too TurboGears, and I'm starting with a very simple
> application.
> When I fill the form with characters like "çã", turbogear gives an
> error like:
>     UnicodeEncodeError: 'ascii' codec can't encode character u'\xe7'
> in position 82: ordinal not in range(128) 

Hello,

Take a look at the /etc/python2.4/site.py file (it may have other name
depending on your GNU/Linux distribution, or on Windows). It probably
has something like:

encoding = 'ascii'

Replace this with:

encoding = 'utf-8'

Also make sure your code and templates are written in UTF-8, and that
your resulting html pages have content types declaring the charset as
being UTF-8.

See you,

-- 
Gustavo Noronha Silva <[EMAIL PROTECTED]>


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---

Reply via email to