Re: [Zope] Namespace confusion
Joel Burton writes:
.... <adtml-call "REQUEST.set('id', 'discuss')"> <adtml-call "REQUEST.set('title', 'Discussion Area')">
<dtml-with "manage_addProduct['JDiscuss']"> <dtml-call "JDiscuss_Folder_add( _.None, _)"> </dtml-with>
</dtml-with> .... The problem is that it overwrites the current values of title and id, so I can refer later to the book title and id.
I've tried to do this like wrap the JDiscuss_add in <dtml-let> or <dtml-with> bands to supply a namespace for the title and id, but haven't been successful.... would work, but it doesn't. (No error, just doesn't use the new id or title.) Apparently, the "JDiscuss_Folder_add" only looks on "REQUEST" and not on the namespace.
Do you have control over it? Then, you may change it. Otherwise, you may try <dtml-let REQUEST="{ ... your assignments ...}"> .... <dtml-call "JDiscuss_Folder_add(_.None,_)"> </dtml-let> May be difficult, as the true "REQUEST" is quite complex and may be difficult to emulate in a dictionary sufficiently for your "add". Dieter
On Wed, 14 Mar 2001, Dieter Maurer wrote:
Apparently, the "JDiscuss_Folder_add" only looks on "REQUEST" and not on the namespace.
Erm, it's just the standard ZClass _add method. How could I get it to look elsewhere on the namespace? -- Joel Burton <jburton@scw.org> Director of Information Systems, Support Center of Washington
participants (2)
-
Dieter Maurer -
Joel Burton