...

View Full Version : same input fields but 2 submits & 2 actions?



Echostorm
04-13-2005, 05:56 PM
Hey all,
Ive seen people use 2 submits on 1 form. However my dilema is this. I have 2 forms, 2 submits, and 1 set of input fields. I need 2 forms because one is sent to my formail.php and the other is sent to paypal for online ordering. Both of the forms have there own submit button but is it possible for them to share fields?

Echo

hemebond
04-13-2005, 11:17 PM
Is there a reason you can't do things properly and have 2 seperate forms? What happens if the user has Javascript disabled?

Echostorm
04-14-2005, 01:10 AM
Yes there is.

I have an option where people can buy a photo online. The buyer selects in which format framed ect.. This is all on the one page. If it wasnt on the same page I wouldnt have the photo number to submit to the order form. My only other option in this situation is to have a token or something. i.e. %photonumber% which a script reads and then puts the %photonumber% into 2 fields.

hemebond
04-14-2005, 05:55 AM
My only other option in this situation is to have a token or something. i.e. %photonumber% which a script reads and then puts the %photonumber% into 2 fields.If both forms need that variable that's exactly what you should be doing.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum