[Zope-DB] DMTL and DateTime or... mxDateTime

Eric Kamm eric@analyticinnovations.com
Thu, 8 May 2003 13:03:32 -0500


Search for "datetime" in the Zope help system and then 
read about the methods the DateTime object supports.

For example...

    <dtml-var "start_date.year()">
    <dtml-var "start_date.AMPMMinutes()">

The DateTime object has dozens of very useful methods
to help you with rendering among other things.

Eric Kamm
Analytic Innovations, LLC

-----Original Message-----
From: zope-db-admin@zope.org [mailto:zope-db-admin@zope.org]On Behalf Of
David Wilbur
Sent: Thursday, May 08, 2003 10:59 AM
To: zope-db@zope.org
Subject: [Zope-DB] DMTL and DateTime or... mxDateTime


i was wondering of if someone could give me an example of manipulating 
dates in dmtl... like for example with the folloing snipit:

<dtml-in getTask>
<dtml-var task>,  <dtml-var start_date> <br>

all that is meaningful is the date, in fact just the year in this case.  
but, by default, with postgres and psycopy, i am getting the date and 
the time.  i tried, form the DateTime definitions get it to change the 
date to just year... but in several of the permutations that i have 
tried it actually seem to send  zope off to nana land (ie: non responsive).

so... i was hoping that i could be given enough of an example to know 
how to get back the year, and also how one would sperate out a date and 
time.  so that i could move on...  also, since i have mxDateTime 
installed, and there is a lot of indications that it is "better".  if i 
use that instead, is the answer effectivly the same or does it have a 
different syntax.  


Zope-DB mailing list