[Zope] Zope tal/dtml syntax for results from external method...

Jeffrey Hood jhood@hmcon.com
Wed, 25 Jun 2003 09:34:06 -0400


I finally got my external method call working, and returning values... 
using <dtml-var getRecords> it prints:
{u'item': [['1', 'Fido', '5.00'], ['2', 'Spot', '10.00'], ['4', 'Sparky',
'24'], ['9', 'Buffy', '10'], ['10', 'Bobby', '50']]}

the code for the above is:
from SOAPpy import SOAPProxy

def getAllRows():
        server = SOAPProxy( "http:..." )
        rows = server.getAll()
        return rows

I can (in a python script) do:
for row in rows:
        print row[0]
        ...

I have been trying everything that I can think of to do the same in dtml, or
preferably, tal...  

Could anyone post a snipit that would show how to get each element in a var
and then access the positional element?

Thanks in advance...

JH

jhood -
hmcon com