views:

22

answers:

3

This probably an easy thing to do but for some reason I can't get a handle on it.

I have a simple form that allows people to select one if three items for sale. When they chose their item I need to pass that variable into an iFrame with a third party checkout page to safely process their cc transaction.

How would I do this?

Cheers-

+1  A: 

On the URL is the easiest

gbn
+2  A: 

The simplest, even JavaScript-less way to do this is giving the iframe a name attribute:

<iframe name="order_confirmation" id="order_confirmation" src="">

(I'm not 100% sure right now whether it's also id or just name you can use, I'm pretty sure it's name)

and then using that name as the target in the form:

<form action='whatever' target='order_confirmation' ....>

the form will then be submitted into the iframe.

Pekka
A: 

Easiest way is to put it on the url. For instance if they select item1 then: http://checkout.com?ID=Item1.

Jake