Use document.form.action property for specifying the url
Say something like this
<FORM METHOD = POST NAME="thisform">
<Form elements out here like text box >
<input type = button1 value="button1 onlick=func1();">
<input type = button2 value="button2 onlick=func2();">
</form>
<script language="javascript">
func1() {
document.thisform.action="URL";
document.thisform.submit();
}
func2() {
//do processing
document.thisform.action="URL";
document.thisform.submit();
}
</script>
</body>
</html>
> -----Original Message-----
> From: Dheil Corona
> Sent: Monday, June 19, 2000 1:06 PM
> To: [EMAIL PROTECTED]
> Subject: how can i have 2 actions..
>
> hi pipol,
>
> can anyone help with this:
> i have a big problem on form submission..
>
> how can i manage 2 action in one form
> for ex. sumit1 will go to link1
> and link1 process some parameters passed by the forms elments
> and submit2 will go to link2, same thing its also pass parameters..
>
> thank you..
>
> -dheil
>
> ==========================================================================
> =
> 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