Purchase by affilate

I have to apply a 10% discount if the buyer is an affilate AND if the $cart_subtotal < 100

I was thinking about writing a function, but how can I check if the user in an affilate?

Do you have an alternative solution in mind?

Thank you

Posted in

Comments

One response to “Purchase by affilate”

  1. Hi Rocco,

    I also think you need a custom function for this and IMO the easiest way would be to apply a predefined coupon if the conditions are met. In order to check if the customer is an affiliate you should use the function affiliates_get_user_affiliate.

    Hope it helps.

    Cheers,
    George

Share