Stephan Goeldi wrote at 2003-5-26 15:03 +0200:
It's a question of someone that did not read the available documentation carefully...
I read it very carefully, but don't seem to be the ideal target group ;-)
My problem is, that I see this example in the query:
title == ’spam’ or PrincipiaSearchSource == ’spam’
I would now replace the word 'spam' with a word, entered in a search form. I tried:
<dtml-in expr="Catalog.query(title == &dtml-word or PrincipiaSearchSource == &dtml-word)">
which doesn't work (same for some variants of the above).
Do you believe me now, that I am a newbie?
Apparently, you are also a person who does not like to read :-( I am sure, I not only wrote the (potentially insulting) phrase quoted above but also listed two options for you. 1. Use Python's format operator ("%") (see Python Library Reference) 2. Use ZCatalogQuery's parameter interpolation (see the ZCatalogQuery documentation). I looked it up for you: It is the "CatalogQuery-HowTo" document, section "Expressions in Queries". There is an example there, ready to use.... And as the above 'expr="...&dtml-XXX;"' indicates additional need for background reading, you should read the Zope Book or maybe <http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html> You can be sure that without carefull background reading, your work with Zope will take at least an order of magnitude longer than necessary. Dieter