#1081: strftime uses locale-dependant encoding
--------------------------------------+-------------------------------------
Reporter: [EMAIL PROTECTED] | Owner: cmlenz
Type: defect | Status: closed
Priority: normal | Milestone: 0.9
Component: general | Version: devel
Severity: normal | Resolution: fixed
Keywords: strftime locale encoding |
--------------------------------------+-------------------------------------
Comment (by anonymous):
i must be retarded as well...
{{{
import locale
encoding = locale.getlocale()[1]
UTF8time = time.strftime(format,t).decode(encoding)
}}}
note that locale.setlocale() may have to be used prior.
--
Ticket URL: <http://trac.edgewall.org/ticket/1081#comment:10>
The Trac Project <http://trac.edgewall.com/>
_______________________________________________
Trac-Tickets mailing list
[email protected]
http://lists.edgewall.com/mailman/listinfo/trac-tickets