[Zope] Python2.3 datetime VS Zope DateTime
Small Business Services
toolkit at magma.ca
Fri Mar 26 07:20:42 EST 2004
From: "Sakesun Roykiattisak" <sakesun at boonthavorn.com>
> I'm now trying to publish a set of database-related logics through
> zope. Some of them return a python2.3's datetime object which its
> member access are disallowed from zope. (DTML, ZPT)
> I want to access some of datetime's member-methods, like strftime &
> isocalendar. How can I make it accessible from zope ? Or how can I make
> Zope automagically convert it to Zope's DateTime. I really don't want
> to change my logics to use Zope's DateTime.
DateTime and strftime are accessible from dtml:
<dtml-let e="_.DateTime()">
strftime(%Y/%m/%d) --> <dtml-var expr="e.strftime('%Y/%m/%d')">
</dtml-let>
Jonathan
More information about the Zope
mailing list