Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Two Submits?

Reply
Thread Tools

Two Submits?

 
 
James Baker
Guest
Posts: n/a
 
      06-10-2004
Once again, trying to re-learn ASP with all of my might. Probably a simple
problem, but here goes:

I have a form that current has a fair amount of data/input tags and a button
that submits it to another page for processing. I'm building another button
on this same page that will post to an entirely different page, but needs a
lot of the same data as the original button. I assume I can't have both
submit buttons within the same form, yet I need access to the same data.
I'm probably missing something pretty obvious, but I can't figure this out
for the life of me.

TIA,
James


 
Reply With Quote
 
 
 
 
Patrice
Guest
Posts: n/a
 
      06-10-2004
You can change the "action" attribute of the form tag to change the page to
which you submit those data. All dates within the form tag will be submitted
(you can just ignore those you don't want).
Looks a bit weird (don't you loose some changes if you clicked on the
"wrong" button ?)

My personal preference is to submit to the same page. You can test which
button was clicked (you'll get the value of the pressed button server side
so that you can perform the appropriate action.

Patrice

"James Baker" <(E-Mail Removed)> a écrit dans le message de
news:(E-Mail Removed)...
> Once again, trying to re-learn ASP with all of my might. Probably a

simple
> problem, but here goes:
>
> I have a form that current has a fair amount of data/input tags and a

button
> that submits it to another page for processing. I'm building another

button
> on this same page that will post to an entirely different page, but needs

a
> lot of the same data as the original button. I assume I can't have both
> submit buttons within the same form, yet I need access to the same data.
> I'm probably missing something pretty obvious, but I can't figure this out
> for the life of me.
>
> TIA,
> James
>
>



 
Reply With Quote
 
 
 
 
Aaron [SQL Server MVP]
Guest
Posts: n/a
 
      06-10-2004
Why does it have to be a submit button?

<input type=button onclick='...do some javascript stuff and submit the
form...'>

Not really an ASP question, you should find techniques for changing the
form's action parameter (depending on the button clicked) in a client-side
group, like microsoft.public.scripting.jscript

--
http://www.aspfaq.com/
(Reverse address to reply.)




"James Baker" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Once again, trying to re-learn ASP with all of my might. Probably a

simple
> problem, but here goes:
>
> I have a form that current has a fair amount of data/input tags and a

button
> that submits it to another page for processing. I'm building another

button
> on this same page that will post to an entirely different page, but needs

a
> lot of the same data as the original button. I assume I can't have both
> submit buttons within the same form, yet I need access to the same data.
> I'm probably missing something pretty obvious, but I can't figure this out
> for the life of me.
>
> TIA,
> James
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
(8-bit binary to two digit bcd) or (8-bit binary to two digit seven segment) Fangs VHDL 3 10-26-2008 06:41 AM
How to compare two SOAP Envelope or two Document or two XML files GenxLogic Java 3 12-06-2006 08:41 PM
Router with NAT and two T1 and two ISP's John Cisco 4 10-16-2004 02:03 AM
Two ISP -Two Routers - 1 PIX James Parks Cisco 5 12-11-2003 08:55 PM
Cisco 2611 with Two T1 from two ISPs Adam Embrey Cisco 3 07-24-2003 10:22 PM



Advertisments