Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

submitting a form twice

Status
Not open for further replies.
Dec 14, 2000
4
0
0
US
I have a form that should have two submit buttons. One to post the data to the database, and the other to carry certain variables over to the next page.

Problem is, only one works. It seems the same form will not be posted twice.

e.g.
<form name=name method=post>
<some fields here>
<input type = submit onClick&quot;JavaScript:document.form.action='currentpage.jsp'&quot;>
(this will post the data to the database)

<input type = submit onClick&quot;JavaScript:document.form.action='nextpage.jsp'&quot;>
(this should post the data on the next page, but doesn't.)

Whichever is pressed first works. The second one doesn't.

Thanks in advance for your help.

 
umm, you cant do that...

you'll need to include code on the page that submits the data to the database to redirect you and your variables to the next page.

you can't submit the same form twice. adam@aauser.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top