[Zope] TAL / Z SQL Method
Geir Bækholt
Geir Bækholt <geirh@funcom.com>
Mon, 3 Feb 2003 15:29:35 +0100
on or about, Monday, February 03, 2003, we have reason to believe that Arja=
n Huijzer wrote
something along the lines of :
> I am having a problem with calling multiple Z SQL
> Methods from within Page Templates. What I need to
> accomplish is calling a Z SQL Method using a parameter
> value from another Z SQL Method.=20
> My code looks like:
> <p tal:repeat=3D"cd container/z_sql_methods/select_cd">
> <span tal:replace=3D"cd/cd_title">CD Title</span>
> <ul tal:repeat=3D"song
> container/z_sql_methods/select_songs">
> <li content=3D"song/song_title">Song Tile</li>=20
> </ul>
> </p>
You'll have to use a python statement:
something like this:
<ul>
<li tal:repeat=3D"song python:container.z_sql_methods.select_songs(cd=
=3Dcd.cd_id)"
tal:content=3D"song/song_title">
Song Tile
</li>
</ul>
Note that i also moved your repeat statement into the <li>, so that you
get list items for each song, not a new list with one item..
:)
--=20
Geir B=E6kholt geir@funcom.com
Web Application/HCI-designer
Product Operations
Funcom Oslo