The easiest thing is possibly to use separate forms.  If that is not an
option, you can make the <input type="submit"...  a <input
type="button", or the <input type="image" to  <a href...><img src...

For the href or the javascript "OnClick" handler, you can use some
javascript like
Add:
document.forms[0].method="post", document.forms[0].submit()

Find
document.forms[0].method="get", document.forms[0].submit()

Theres absolutely no reason why you can use javascript in jsp - thats a
client side thing and can be generated in any server side scripting
thing

Biren Patnaik wrote:
>
>  Hi All,
> > I m facing one problem in JSP.Can I use GET and POST both in a JSP
> > program simultaneously .That means Suppose I want to use both
> > simultaneously in a form,then what should I do?.BeCos I m writing one
> > program which will consist of 2 buttons they r "Add","Find",.So for Add
>   we have to write <form method = "POST" and for Find we have to write
> <form method = "GET".Is there any soln for that..
> Can We use JavaScript in JSP?.
> > Thanx in advance
> > Biren
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

--
Regards

Steve Bradshaw

Software Developer, Autonomy Systems Ltd.
St. John's Innovation Centre - Cowley Road - Cambridge - CB4 0WS -
UK
Web: http://www.autonomy.com/
Tel: +44 1223 422460
Fax: +44 1223 421583

The information contained in this message is for the intended addressee
only and may contain confidential and/or privileged information.  If you
are not the intended addressee, please delete this message and notify
the sender; do not copy or distribute this message or disclose its
contents to anyone.  Any views or opinions expressed in this message are
those of the author and do not necessarily represent those of Autonomy
Systems Limited or of any of its associated companies.  No reliance may
be placed on this message without written confirmation from an
authorised representative of the company

*** Have a taste of Autonomy's technology for free.
Download Kenjin at www.kenjin.com ***

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to