Two Payment Options For One Product

Is it possible to have two payment options show up on the Foxy checkout page for one product?

I work for a college and we offer both a credit and non-credit version of each of our courses at different price points. In our current ("home-grown") checkout page, we give the user the choice (using radio buttons) of selecting one or the other. The page dynamically changes the price in the cart when the user selects one or the other.

If you'd like to see what I mean, go to https://online.berklee.edu/courses, click on a course title then click the Enroll Now button. That will put you on our checkout page. It defaults to the "credit" price. If you click the "non-credit" radio button, you'll see the price in the cart change accordingly.

Is something like that possible in Foxy?
Tagged:
Comments
  • fc_adamfc_adam FoxyCart Team
    @tkates1foxy,

    Something like that is possible - but we would recommend having the two options for credit or non-credit as part of the add to cart itself if that could work for your requirements.

    Once a product is added to the cart, we don't support changing it's price without removing and re-adding the product at it's modified price. That is possible with javascript on the checkout, but can get a little involved. Alternatively, you could also dynamically add/remove a coupon to account for the price difference - but that may get difficult if you need to support multiple different courses in the cart at the same time, or if the price adjustment isn't consistent across different products.

    If you're able to add the selection as part of the add to cart though - then you can adjust the price using our product option modifiers. For example, that could look like this:
    <input type="hidden" name="name" value="My Course">
    <input type="hidden" name="price" value="200">
    <label for="credit"><input type="checkbox" id="credit" name="type" value="Credit">For Credit ($200)</label>
    <label for="non-credit"><input type="checkbox" id="non-credit" name="type" value="Non-Credit{p:180}"> Non-Credit ($180)</label>
    If someone selected the "For Credit" option, then the normal price will apply ($200 above). If someone selected the "Non-Credit" option, then the price will be $180 once added to the cart instead.

    Could that work for your needs?
  • That might work. I'll take a look at those modifiers.

    Thanks!
Sign In or Register to comment.