[Zope] external methods
Service Informatique CHSR
chsrinfo@guetali.fr
Fri, 26 Mar 1999 15:47:52 +0400
Hello,
I'm confused with external methods. Please help.
I want an external method to access its context (for the
purpose of acquisition, etc.). So I write:
def myExtMethod(self):
pass
Within myExtMethod, I should be able to:
- write self.REQUEST to access the current REQUEST object (I
need to be able to modify the current REQUEST object with
self.REQUEST.set(...))
- or for example self.myzsqlmethod() to call a zsql method object,
right???
Let's suppose that myExtMethod is:
def myExtMethod(self):
l=[]
for i in self.l:
l.append(i+1)
self.REQUEST.set('l', l)
Now, how can I call this method from DTML?
<!--#var myExtMethod-->
<!--#var "myExtMethod()"-->
<!--#var "myExtMethod(this())"-->
All don't work. I end up in a traceback. "read only class, buffer"
Any hints?
Jepthe CLAIN
Service Informatique CHSR