[Zope] dtml date comparsion help
Kelley, Sean
SKelley@ci.santa-rosa.ca.us
Mon, 4 Nov 2002 14:02:56 -0800
Hi,
Trying to get more familiar with dtml...
How do I do a date comparison with dtml-in?
I have:
<dtml-in "portal_catalog.searchResults( meta_type='CMF Event'
, sort_on='Date'
, sort_order='reverse'
, Subject='All Utilities'
, review_state='published'
)" size="10">
Some stuff
</dtml-in>
I want to insert a dtml statement so that only the CMF events that are on or
after today show up. Do I do my date comparison in the first line somehow
or with a dtml-if a little later? I am trying to say if Date (date
mm/dd/yy) >= ZopeTime (date mm/dd/yy) do something. Problem is that I it
seems I need to use the fmt attribute on the date comparison so I am a
little comfused about syntax.
tried something like:
<dtml-if expr="Date fmt='%m/%d/%Y' >= ZopeTime fmt='%m/%d/%Y'"> but I do
not have the syntax right.