newbie: problems with setting title when cloning a dtml-method
hi guys, a short python-question. i have a script quite similar to the one in the zope book. it looks like this. """ parameters: id ,document_title, REQUEST=None ----------------------------------- Copy the template to the calling folder """ # Clone the template, giving it the new ID. This will be placed # in the current context (the place the factory was called from). exhibit=context.manage_clone(container.new,id,document_title) # Change the clone's title exhibit.manage_changeProperties(document_title=document_title) # If called through the web, redirect back to the context if REQUEST is not None: try: u=context.DestinationURL() except: u=REQUEST['URL1'] REQUEST.RESPONSE.redirect(u+'/manage_main?update_menu=1') i use it for a mechanism to construct user-specific methods, folders and docs. "new" is a dtml-method. how can i set the duplicated method's title? it works very well if "new" is a document, then i can set the title via parameter "title". i don't know the exact command for methods, i think the problem is that a method does not have real properties? cheers, jan -- Sent through GMX FreeMail - http://www.gmx.net
Jan Sew writes:
exhibit.manage_changeProperties(title=document_title) ... does not work for DTML Method ....
Try: exhibit.title= document_title It may be possible that the security system will not let you do this assignment. Then you will need an External Method. Dieter
participants (2)
-
Dieter Maurer -
Jan Sew