[Zope] The ZPublisher :method type (was RE: [Zope] detail record editing ) )

Jeffrey Shell Jeffrey@digicool.com
Tue, 6 Jun 2000 11:10:30 -0400


> My solution for this kind of problem is to have a DTML method 
> that delegates
> to the
> appropriate DTML methods. Therefore each button gets a value 
> and a name, eg.
> <input type=submit name=action value=delete>
> <input type=submit name=action value=modify>

Actually, you can use the Bobo ":method" type.  It's
documented...somewhere :).

You can do:

<input type="submit" name="mthDelete:method" value="delete">
<input type="submit" name="mthModify:method" value="modify">

and the Publisher will add the selected method to the end of the path.
Make your form action be &dtml-URL1; or "./"

There's a default_method type too, I think you *might* see it in action
on the "Rename" form in the Zope management screens.