I have found myself in the position of needing an external method to accomplish a task. However, I have not found enough information that (by example) shows me how to return something that will be processed by a dtml-in statement. I am replacing the old SQLMethod within the dtml-in with an external method. Therefore, the current code is looking for various SQL fields to exist in the returned result set. How do I do this? A Python example would be GREATLY appreciated! I am writing my first python as well. I learn best by example. Thanks so much, Clayton. ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com
Clayton, in an external method named emReturnStuff: def ReturnStuff(argument): if argument=="this list": return ['1', '2', '3'] elif argument=="that": return ['4', '5', '6'] else: return ['0'] in a DTML method named dtShowStuff: <dtml-var standard_html_header> <dtml-in "emReturnStuff('this')"> <dtml-var sequence-item><br> </dtml-in> <dtml-var standard_html_footer> calling dtShowStuff should show: 1 2 3 changing the argument within dtShowStuff should return different lists. etc. untested., Clayton Miller wrote:
I have found myself in the position of needing an external method to accomplish a task. However, I have not found enough information that (by example) shows me how to return something that will be processed by a dtml-in statement. I am replacing the old SQLMethod within the dtml-in with an external method. Therefore, the current code is looking for various SQL fields to exist in the returned result set. How do I do this? A Python example would be GREATLY appreciated! I am writing my first python as well. I learn best by example. Thanks so much, Clayton. ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com
_______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
-- Chris McDonough - Digital Creations, Inc. Publishers of Zope - http://www.zope.org
participants (2)
-
Chris McDonough -
Clayton Miller