[Zope] Zcatalog and PrincipiaSearchSource with Zclasses ?

gtk gtk@well.com
Sat, 23 Oct 1999 15:40:21 +1000


> >Sure, why not just impliment a DTML Method in your ZClass called
> >PrincipiaSearchSource that returns what you want indexed?
> >
> ><dtml-return "title + author + body">
>
> This won't work, because you can't index on the result of a DTML Method.

PythonMethod is perfect for this kind of thing. I just created
PrincipiaSearchSource with code:

    return self.id+"; "+self.title+"; "+self.text

... and then re-indexed everything (so the catalog picked up on the method)
and performed a search. Worked a treat!

Regards,
Garth.

--
<gtk@well.com>