Re: newforms: UnicodeEncodeError raised when using any non-unicode charset

2007-01-24 Thread ak
Well I've got success after applying a patch to django's code. Actually there are 2 patches against django/db/backends/mysql/base.py: 1. it forces to run SET NAMES 'utf8' after connection. This is wrong, and I replaced it with SET NAMES 'cp1251'. Ofcourse, it should be a setting in settings.py but

newforms: UnicodeEncodeError raised when using any non-unicode charset

2007-01-24 Thread ak
Hello again It seems like newforms library has a problem with non unicode charsets yet. For example, I use 'windows-1251' character set for my web apps and MySQL 4.1 with 'cp1251' so actually all data is stored and shown in cp1251. And here's what I get when try to save any form with national (n