Hello, Previously I made a DTML method that when used within a DTML Document would modify properties on that document. Having this floating around in root made it visible to the whole site, but seemed 'unclean'. So, I attempted to make the DTML method into a ZClass, and making the index_html method in the ZClass contain the exact same DTML as the method... But it doesn't work. So, I tried again - this time with as simple a method as possible, a very basic counter. The DTML method I made in root increments and displays the 'z_count' property on the page that calls it, and creates the property if it doesn't exist, so using it is as simple as: <dtml-var mycount> However, I place the DTML into a new class, and then make a new instance of the class, and it wont work as above. I now have to do this: <dtml-with MyZCCount> <dtml-var MyZCCount> </dtml-with> And, instead of modifying the property of the calling document, it modifies the parent folder's properties. Below is the DTML, can someone please explain what I need to do to get this to work on the calling DTML document instead? If I can't get this simple counter to work I'm going to go mad, since changing properties is something I need to be able to do from many of my planned ZClasses... Thanks in advance! <dtml-if "hasProperty('z_count')"> <dtml-var "'%06d' % (z_count + 1)"> <dtml-call "REQUEST.set('z_count', z_count + 1)"> <dtml-call "manage_changeProperties(REQUEST)"> <dtml-else> <dtml-call "manage_addProperty('z_count', 1, 'int' )"> 000001 <dtml-if>
Jon Franz wrote:
<dtml-var mycount>
However, I place the DTML into a new class, and then make a new instance of the class, and it wont work as above. I now have to do this:
<dtml-with MyZCCount> <dtml-var MyZCCount> </dtml-with>
And, instead of modifying the property of the calling document, it modifies the parent folder's properties. Below is the DTML, can someone please explain what I need to do to get this to
I hope someone can answer this. I am having a similar problem. I posted yesterday but haven't received an answer yet either. There is a significant difference in the way properties get changed in a ZClass depending on it being a folderish property or a document property. Trouble is I have figured out those differences. <g> Can someone shed some light on this? -- Tim Cook -- FreePM Project Coordinator http://www.freepm.org OS Health Care Alliance Supporter http://www.oshca.org
on 9/8/00 3:18 PM, Steve Drees at drees@the-bridge.net wrote:
Is anybody running zope on a Mac OS 8.x or 9?
Python 1.5.2 and before for Mac is not threaded, so it doesn't support Zope. 1.6 for Mac is reportedly threaded, but there are some remaining problems (i.e., I tried it once and didn't get a successful compile). I haven't had a chance to follow it up further. Mac OS X make make this moot. I haven't had the opportunity to try it yet, but I believe Zope has been run on OS X Server. I don't know whether anyone has tried with the developer releases of OS X, but I'm planning to give it a shot with the beta release when it's available. Jim Harrison University of Pittsburgh
HI Steve, I've been running Zope-2.2 on my powerbook under MacOSX DP4 quite happily. My only problem now is lack of MySQL ;-). I don't think there's much hope of Zope on MacOS 8/9 due to the lack of proper thread support. I did manage to get Medusa/Bobo working on MacOS-8, a *long* time ago... but that was before threading was added ... and it was horribly slow. There should be a public beta of MacOS-X out soon.. and it runs Zope just fine. (There is some monkey business with gcc command link options that are different from the defaults (e.g., '-LDFLAGS=undefined-suppress') to make the linker happy... take a look at: http://www.zope.org/Members/jshell/buildingZopeOnMacOSXServer ) Good Luck! -steve
participants (5)
-
Jim Harrison -
Jon Franz -
Steve Drees -
Steve Spicklemire -
Tim Cook