3 May
2004
3 May
'04
3:46 a.m.
On Sunday 02 May 2004 02:57 pm, Jim Anderson wrote:
I've reading Zope documentation and python/lib modules and have not found a way to bind to the current folder context when I run my python product in Zope 2.7.
I'm creating the product with a member function, ex(). So for example, if my product is 'sample' and the member function is 'ex', I try executing 'sample.ex()'. Inside ex(), I have the following code:
def ex(self): request = context.REQUEST
The product loads ok, but when ex() is called, I get an error message:
Error Type: NameError Error Value: global name 'context' is not defined
Thanks in advance for any tips.
Try request = self.REQUEST. Alec Mitchell