<div style="direction: ltr;">1) don't make spaces around = in HTML attributes:<br></div><div style="direction: ltr;"><span> tal:define="query here/testquery"<br><br>a mistake<br><br></span></div>
2) Why do you use repeat['result'] ? Can you point us to documentation<br>where did you read it ?<br> tal:replace="result/firstname" should work as expected or<br> tal:replace="python:result[
<div style="direction: ltr;">'firstname']" in case of result is<br>dictionary and you need to use python: for some reason.<br><br><a href="http://wiki.zope.org/ZPT/RepeatVariable">http://wiki.zope.org/ZPT/RepeatVariable
</a><br><br>requires repeat to be called. I used this as previously using tal:replace="result/firstname produced a keyerror as I had no dictionaries set up. The repeat variable sets-up a dictionary automatically...<br>
<br><br>3) what testquery returns ? I suppose it returns method, because you are<br>calling this method wit parameter 'id', but I don't think you meant it
<br>in this way.<br><br>testquery returns a ZSQL query which works and is tested. The id variable is totally meant as we are passing through a dynamic variable from a ZPT page through to the ZSQL query. At the moment to simplify things! (required..) this variable is fixed to 'IT'.
<br><br>Thanks for your help<br></div><br><br><div><span class="gmail_quote">On 11/1/07, <b class="gmail_sendername">Radim Novotny</b> <<a href="mailto:novotny.radim@gmail.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
novotny.radim@gmail.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
michael nt milne napsal(a):<br>> yeah I have modified to this<br>><br>> <li tal:define = "query here/testquery"<br>> tal:repeat="result python:query(id='IT')"><br>> <span tal:replace="python:repeat['result'].firstname">First
<br>> Name</span>&nbsp;<br>> </li><br>><br><br>1) don't make spaces around = in HTML attributes:<br> tal:define="query here/testquery"<br><br>2) Why do you use repeat['result'] ? Can you point us to documentation
<br>where did you read it ?<br> tal:replace="result/firstname" should work as expected or<br> tal:replace="python:result['firstname']" in case of result is<br>dictionary and you need to use python: for some reason.
<br><br>3) what testquery returns ? I suppose it returns method, because you are<br>calling this method wit parameter 'id', but I don't think you meant it<br>in this way.<br><br>--<br>Radim Novotny<br><br>_______________________________________________
<br>Zope maillist - <a href="mailto:Zope@zope.org" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">Zope@zope.org</a><br><a href="http://mail.zope.org/mailman/listinfo/zope" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://mail.zope.org/mailman/listinfo/zope</a><br>** No cross posts or HTML encoding! **<br>
(Related lists -<br> <a href="http://mail.zope.org/mailman/listinfo/zope-announce" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://mail.zope.org/mailman/listinfo/zope-announce</a><br> <a href="http://mail.zope.org/mailman/listinfo/zope-dev" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://mail.zope.org/mailman/listinfo/zope-dev
</a> )<br></blockquote></div><br><br clear="all"><br>-- <br>michael