durusmail: quixote-users: mod_scgi on Apache2
mod_scgi on Apache2
2005-07-18
2005-07-18
2005-07-19
2005-07-30
2005-07-31
2005-07-31
2005-07-21
2005-07-19
mod_scgi on Apache2
Bo Yang
2005-07-31
I'm still using quixote 1.2. (I vaguely remember some file upload
class in 1.2 has a file size method I needed to use, so I didn't
upgrade when 2.0 alpha was out. then our site went live and ain't-
broken-don't-touch) And I'm not using the form framework. Need to be
more flexible with the UI.

I tried to use straight unicode inside quixote, it worked, but it's
too much hassle adding u' to every static string in ptl.  Since the
easiest way to get unicode out of mysql is to execute "set names
utf8" right after I get a connection, I decided to use utf-8 all the
way.

So these are what I had to do to use utf-8 with quixote (again, this
is v1.2):

1. In my publisher class, add:
          request.response.set_content_type('text/html; charset=utf-8')
     to start_request()

2. Add
      # -*- coding: UTF-8 -*-
     to every ptl file, and edit these with an utf-8 enabled editor.

and not exactly quixote per se:

3. In my site-wide html header ptl call, add:
          


pretty straight forward. I have not encountered any problem, other
than wrestling with mysql's unicode implementation and adding encode/
decode when dealing with cElementtree which spits out unicode even
though the xml files themselves are encoded in utf-8.

- bo

On Jul 31, 2005, at 1:02 AM, Neil Schemenauer wrote:

>
>
>> A big thank-you to the quixote team, by the way.
>>
>
> I see you are using utf-8 for your site.  Have you run into any
> Unicode Quixote problems?  I recently fixed a bug in the form
> framework but perhaps you don't use it.
>
>   Neil
>

reply