[ZWeb] Re: Catalog Searching

Chris Withers chrisw@nipltd.com
Thu, 21 Sep 2000 10:21:02 +0100


Maik Roeder wrote:
> That's the code:
> 
> <B>What's new ?</B>
> 
> <dtml-with "PARENTS[-1].SiteIndex">
>  <dtml-call "REQUEST.set('sort_on', 'date')">
>  <dtml-call "REQUEST.set('sort_order', 'reverse')">
>  <dtml-call "REQUEST.set('bobobase_modification_time', _.DateTime()-1)">
>  <dtml-call "REQUEST.set('bobobase_modification_time_usage', 'range:min')">

So I'm guessing this returns any stuff modified during the last day?
(I'll leave out bitching about Catalog and it's unfriendly search
syntax, for a change ;-)

>  <dtml-with "_(results = searchResults(REQUEST=REQUEST))">

What exactly does _(something) do?

> Is there a problem with this solution ? 

Looks okay, but I wonder if you could do a search that returns the 20
last modified objects. I guess a catalog search sorted on
bobobase_modification_time and batched to only return a maximum on 20
results woudl work. Hwo do you formulate this as a Catalog query?

cheers,

Chris