I did this
myString.encode( utf-8 ) before pasing to url_for, is this the
correct Pylonic way?
On Jul 19, 11:46 am, voltron [EMAIL PROTECTED] wrote:
I get this when I pass Unicode strings from a database to url_for
exceptions.Exception: url_for can only return a string or None, got
I get this when I pass Unicode strings from a database to url_for
exceptions.Exception: url_for can only return a string or None, got
unicode instead
How should this case be normally handled?
Thanks
--~--~-~--~~~---~--~~
You received this message because you
On Jul 19, 2007, at 2:58 AM, voltron wrote:
I did this
myString.encode( utf-8 ) before pasing to url_for, is this the
correct Pylonic way?
Yep, url_for can coerce keyword arguments from unicode, but for
passing full raw URL's, they need to be raw strings (ie, encoded).
Cheers,
Ben