[Zope-CMF] Today's News
Dieter Maurer
dieter@handshake.de
Wed, 19 Sep 2001 18:45:43 +0200 (CEST)
D.Turpie@open.ac.uk writes:
> I have created a news box in a portal which lists all the news items.
> However I would also like to create news area which just lists news of the
> day.
>
> The current code below extracts a news item I submitted today and the day
> before.
>
> <dtml-in "portal_catalog.searchResults( meta_type='News Item'
> , sort_on='Title'
> , sort_order='ascending'
> , review_state='published'
> ,
> bobobase_modification_time=_.DateTime()-1
> ,
> bobobase_modification_time_usage='range:min'
> )" size="10">
>
When I remember right, "DateTime" has a method giving you
the starting time of the current day.
Look at the "DateTime" documentation....
Dieter