|
|
If you have the Tapestry in Action book, then look at section 3.4.5 and 3.5
Otherwise look at the Submit/ImageSubmit component. It has a 'tag' and
'selected' parameters that help you to figure out which submit button was
clicked.
I would advise not to have listener methods for each submit button because
these are called before a form rewind happens. Have only one 1
form-submit-listener method and use the 'tag' and 'selected' to take the
appropriate action in the listener method of the form.
Hope this helps,
Saqib
> -----Ursprüngliche Nachricht-----
> Von: RajaSekhar KS [mailto:ks.rajasekhar@xxxxxxxxx]
> Gesendet: Monday, 21 March 2005 11:15 AM
> An: tapestry-user@xxxxxxxxxxxxxxxxxx
> Betreff: Am i doing right for "Form submit"
>
> Hi,
> I am having a form and inside the form i am having submit buttons
> like "New", "Edit", "copy"...etc..
>
> I am writing SEPERATE listeners for each "New", "Edit", "copy". now in
> class file i am defining the methods.
>
> I think i am defining more listeners...
>
> Am i doing the right thing for form?
>
> I want to know can i use one listener for "Form" and can i find which
> button is clicked as we do in jsp.....??? ie...the button clicked is
> ....New/Edit/Copy
>
> Is this the best way or defining separate listeners is a good way...?
>
> Ur suggestion is more appriciated....
>
> Regards,
> RajaSekhar K S
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@xxxxxxxxxxxxxxxxxx
> For additional commands, e-mail: tapestry-user-help@xxxxxxxxxxxxxxxxxx
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@xxxxxxxxxxxxxxxxxx
For additional commands, e-mail: tapestry-user-help@xxxxxxxxxxxxxxxxxx
|
|