Products allow you to define your own objects. This is pretty much the only case in which you'll be using the __init__ constructor. HTH, Dylan At 12:08 AM 11/8/2002 +0800, you wrote:
Hi Chris,
Thanks for your reply.
What I'm not so clear here is what you meant by 'disk-based Python Product'. My understanding is that you cannot call a user defined python script unless you define it as 'Script (Python)'. Also, if you follow the link, it appears that it is a 'Script (Python)' because it is being called from a DTML method.
AL
On Thu, 2002-11-07 at 19:11, Chris Withers wrote:
Alfredo P. Ricafort wrote:
In this location, http://www.zope.org/Members/anthony/tree-coding-tricks, there is a sample python script. If I try to load it in my Zope installation (ver 2.6), it complains because a class and a method starts with "_". But in python, the class initialization method __init__ starts "_".
So how do you define a class that requires an initialization method in a Zope?
if you're trying to use Script (Python)'s to play around with this, don't, they're not designed for it ;-)
You probably want to look at writing a disk-based Python Product in which you can do anything you want.
cheers,
Chris
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )