[Zope-CMF] Problems translating CMFDefault

Gitte Wange gitte@mmmanager.org
Thu, 19 Dec 2002 08:02:29 +0100


On Thursday 19 December 2002 06:34 am, Paul Winkler wrote:
> On Wed, Dec 18, 2002 at 12:42:02PM +0100, Gitte Wange wrote:
> > Anybody here would mind if I make a small adjustment to the edit scri=
pts?
> > I will give the submit buttons a name and see if REQUEST contains thi=
s
> > name instead of the behaviour that exists now ...
>
> You don't need to examine the REQUEST.
> If each button is supposed to submit to a different script,
> you can use the "scriptname:action" parameter converter
> in your form:
>
> <form action=3D"my_folder">
> <input type=3D"submit" value=3D"my translated text"
>  name=3D"script_1:action" />
> </form>
>
> If you click on that submit button, your form will submit to
> my_folder/script_1
>
>
> See "Advanced Zope Scripting" in the Zope book,
> section "Passing Parameters to Scripts".

Hey,

No the problem is not that the form should submit to 2 different scripts.=
 The=20
problem is that within the edit script it returns to either the view page=
 or=20
the edit page, depending on that button the user clicked on (e.g. in the=20
document_edit.py script). And then it looks for the value of the button=20
(which will be different depending on what language you use). Instead it=20
should look for the name of the button.

Hope this is more clear :-))
I'm not good at explaining this ...=20

Greetings,
Gitte Wange