yeah I have modified to this

<li tal:define = "query here/testquery"
     tal:repeat="result python:query(id='IT')">
<span tal:replace="python:repeat['result'].firstname">First
Name</span>&nbsp;
  </li>

but get this as a result. Thanks for the reply.

Module Products.PTProfiler.ProfilerPatch, line 32, in __patched_call__
Module Products.PageTemplates.ZRPythonExpr, line 47, in __call__
- __traceback_info__: query(id='IT')
Module Python expression "query(id='IT')", line 1, in <expression>
AttributeError: Results instance has no __call__ method

On 11/1/07, Paul Winkler <[EMAIL PROTECTED]> wrote:
>
> On Thu, Nov 01, 2007 at 12:48:04PM +0000, michael nt milne wrote:
> > Hi
> >
> > I've got this piece of code which is returning a keyerror on 'results'
> as I
> > haven't set up a dictionary for the variables.
> (snip)
> > <span tal:define="query here/testquery">
> > <li tal content="results python: query(id='IT')">
> > <span tal:replace="results/firstname">First Name</span>&nbsp;
> > </li>
>
> "<li tal content" doesn't make any sense.
>
> I suspect you want that to be:
>
> <li tal:define="results ...
>
>
> --
>
> Paul Winkler
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists -
> http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope-dev )
>



-- 
michael
_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to