[Zope-dev] DTML processing variable
David W. Damon
dwdamon@home.com
Fri, 10 Nov 2000 14:04:52 -0500
Hey all,
I'm having difficulty getting dtml-in to iterate over a list of strings
returned from an external python method.
Essentially, I have a string that is comprised of the contents of an HTML text
area. I need to split the string into a list of words and iterate over this
list.
My external python method is this:
def stringSplit( self, theString ):
return string.split( theString )
Heres the pertinent DTML.....
-------------------
<dtml-call expr="REQUEST.set( 'userList', stringSplit(acctUsersEmail))">
<dtml-in userList>
<dtml-var sequence_item>
</dtml-in>
<dtml-var REQUEST>
-------------------
If I comment out the dtml-in block, i have a userList variable in the REQUEST
object that is something like: ['name1', 'name2', 'name3']
Any ideas?
-- dave