4

I am looking for an easy way to associate two products with each other on checkout while at the same time forcing the user to create the association if it doesn't exist yet. Basically, a user can by hosting, but in order to complete the checkout, they also need a domain name. I have classes for each, but I am trying to think of ways to solve two problems:

  1. On checkout, display that two products are associated
  2. Force the user to create the association

Any ideas on what I can use to do that?

UPDATE

What I did was:

  1. Created two separate products
  2. If you add the one, it does a check to see if this item has been linked to another product
  3. If not, it takes you to a custom page forcing you to add and assign the other product

This works, but it's not very elegant. Any better suggestions would be much appreciated.

1 Answer 1

0

Use Rules to display messages to the user. Use the event on "add to cart", check the type of product, then check to see if the associated product is added to the cart, if not show message saying you also need to add a hosting package and auto redirect them there. Then upon checkout, check to see if one of those products exist, does the other exist in the cart? Throw same message and auto redirect them to the missing one.

You may need to use components with your rules to get the full effect. But that is what I would do.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.