Yes. Use JavaScript.
I assume your talking about the Struts framework..actions?
<input type="submit" onclick="this.form.action='/path.do'" value="Action 1">
<input type="submit" onclick="this.form.action='/path2.do'" value="Action
2">
That should do it. You can also pass a COMMAND name. I wrote some reflectino
code that allows me to do this:
<input type="submit" onclick="this.form.action='/path.do?command=Search'"
value="Search">
When clicked, it passes a request parameter called "command" with the value
of "Seach". I have a DefaultAction class that implements the perform()
method. In that method, I use reflection to get the command value (if
command paramter does not exist, it defaults to "Default"). It then puts
together a method called executeCommandXXX where XXX is the name of the
parameter 'command' value. It then executes that method. This allows me to
extend DefaultAction with various action classes, and simply use the last
part of the name of a method in each action, and it gets called for me
automatically. This way, I use one action class to handle multiple actions
that are related.
> -----Original Message-----
> From: Prakash [mailto:[EMAIL PROTECTED]]
> Sent: Saturday, September 09, 2000 5:55 PM
> To: [EMAIL PROTECTED]
> Subject: Can we have two actions in same jsp page
>
>
> Hi,
>
> Can we have two actions from one jsp page
>
> Prakash D.
>
> ==============================================================
> =============
> To unsubscribe: mailto [EMAIL PROTECTED] with body:
> "signoff JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets