[Zope] Zope Extensions

Dennis Allison allison@sumeru.stanford.EDU
Mon, 14 Jul 2003 07:28:02 -0700 (PDT)


If your Extensions use a signature of the form

def myextension( self, ... ):
	...

self will usually have the container/context value.  Check the Zope Book
and the Development Guide for the rules.

On 14 Jul 2003, Patrick W. Fraley wrote:

> Hi,
> 
> I posted earlier a question about importing python standard modules,
> which I solved by using the Extension directory.
> 
> Now is it possible for a script in that directory to access the context
> object?  I do have a lot of sql routines, which I would like to access
> from the extension script by using the context object.  When I try that
> I do get an error global name 'context' is not defined.  Which module do
> I have to import in order to get access to this?
> 
> TIA
> Patrick W. Fraley
> -- 
> 
> ***************************************
> COMsulting Gerhard Faehling GmbH
> Patrick W. Fraley
> Oeverdieker Weg 6
> 23669 Timmendorfer Strand
> Tel: 04503 / 88 12 45
> Fax: 04503 / 88 10 18
> E-Mail: pf@comsulting.de
> Internet: www.comsulting.de
> ***************************************
> 
> 
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://mail.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists - 
>  http://mail.zope.org/mailman/listinfo/zope-announce
>  http://mail.zope.org/mailman/listinfo/zope-dev )
>