[Zope] more help with externs, please . . .
David Wagle
david.a.wagle@healthpartners.com
Wed, 17 Feb 1999 11:44:54 -0600 (CST)
Ok, I thought I had a handle on this after Amos' message
yesterday . . .but I clearly don't have a clue as to what
is going on.
I have the following external method:
def dwtest(self,REQUEST=None):
"find out what the hell is going on with REQUEST headers"
if REQUEST is None and hasattr(self,'REQUEST'):
REQUEST=self.REQEUEST
return "REQUEST is None and hasattr(self,'REQUEST')"
elif REQUEST is None and not hasattr(self,'REQUEST'):
return "REQUEST is None. Self does not have attr REQUEST"
elif REQUEST is not None and hasattr(self,'REQUEST'):
return "REQUEST is not None. self has attr REQUEST"
elif REQUEST is not None and not hasattr(self,'REQUEST'):
return "REQUEST is not none. self does not have attr"
If I call it with the URL, I get the expected:
REQUEST is not None. self has attr REQUEST
If I call it with the DTML <!--#var "dwtest('REQUEST')"--> I get:
REQUEST is None. Self does not have attr REQUEST"
???
I am missing somethign really fundamental here, and I don't know
what it is.
Help please. ...
daw
---------------------------------------------
A computer without Microsoft products is like
a dog without bricks chained to its head
---------------------------------------------