Hi, I am using External Methods to execute my business layer logic, and need to have global variables available to me. Unfortunately the global variables in the module I am using do not seem to persist through the session and are being reset as if the module is being re-imported when I click on another link. Can someone please explain this and make any suggestions as to the best way to maintain global python variables accessible to external methods. As you can guess I am a Zope and python newbie so apologies,
Tony Lynch.
A few questions for you. Are the 'global' variables global to the webserver, a session or a user? If global to the server then you could set properties in the root level of where they are needed and then use them in the external method by making use of acquisition, i.e. self.whatever. The other two would be more work, and I'm working on something for session/user variiable tracking as we speak (nothing to show for it yet). Not much help I'm afraid. Phil phil@philh.org ----- Original Message ----- From: Tony Lynch <sight@sight.screaming.net> To: <zope@zope.org> Sent: Saturday, September 25, 1999 12:46 AM Subject: [Zope] Re: Global Variables / External Methods
Hi, I am using External Methods to execute my business layer logic, and need to have global variables available to me. Unfortunately the global variables in the module I am using do not seem to persist through the session and are being reset as if the module is being re-imported when I click on another link. Can someone please explain this and make any suggestions as to the best way to maintain global python variables accessible to external methods. As you can guess I am a Zope and python newbie so apologies,
Tony Lynch.
_______________________________________________ Zope maillist - Zope@zope.org http://www.zope.org/mailman/listinfo/zope
(To receive general Zope announcements, see: http://www.zope.org/mailman/listinfo/zope-announce
For developer-specific issues, zope-dev@zope.org - http://www.zope.org/mailman/listinfo/zope-dev )
participants (2)
-
Phil Harris -
Tony Lynch