File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes multiple image buttons Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "multiple image buttons" Watch "multiple image buttons" New topic

multiple image buttons

sreenivas jeenor
Ranch Hand

Joined: Jan 09, 2005
Posts: 125

I have a situation where i have to place 4 image submit buttons and call the same action,by knowing which image button is pressed ,particular code must be executed.

To my knowledge only one <html:image scr="" property="submit"> can be placed in a page.for multiple action i can use DynamicAction..

Give me a example fopr my siuation....

Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
Lookup the class "ImageButtonBean" in the Struts Javadoc. You will see that if you define properties in ActionForm of this type and assign each property to a particular button, you will be able to tell which image button was pressed.

Consultant, Sima Solutions
I agree. Here's the link:
subject: multiple image buttons
It's not a secret anymore!