Home Forums Plugin Support AffiliateWP MLM How to prevent Coupon used on affiliate link of another affiliate.

3 replies, 4 voices Last updated by Arnoldas Bruzas 4 months, 4 weeks ago
    • David

      Coupon codes and affiliate links – how to block the use of coupon codes on affiliate links.

    • Christian Freeman

      If you want to prevent customers that have been referred by an affiliate from using coupons, you can disable the coupon entry field with this code:

      // Hide coupon field on cart page if affiliate referral is detected
      function affwp_wc_hide_coupon_field_for_referrals( $enabled ) {
      if ( affiliate_wp()->tracking->was_referred() ) {
      $enabled = false;
      return $enabled;
      add_filter( ‘woocommerce_coupons_enabled’, ‘affwp_wc_hide_coupon_field_for_referrals’ );
    • kevinsmith

      I like the discussion above. I quite learned from it and maybe it will help me someday in near future. Well this coding and everything related to this is difficult and not easy to understand. Few days back I was looking forward to some discount coupons site and in this i went through a blog revglue.com/blog-detail/3-how-to-setup-a-responsive-uk-cashback-or-coupons-website-quickly-and-cheaplys which not only provided me with the coupon vouchers I was looking for but also made my mind to start my own discount coupon site with the help of their team. This site has huge amount of data of almost every big international brand and most importantly they keep their data up to date. They have many template to choose the layout of our site. We do not need to learn this much coding when we already have the services of such organizations. By the way i am still looking forward to someone who can suggest me that if I should buy their services or not. Thanks

    • Arnoldas Bruzas

      dynamic coupons is a feature of AffiliateWP, but it doesn’t logically work well with MLM system.
      If one random referral somehow received a dynamic coupon code from affiliate that is not his parent affiliate, the affiliate who owns that coupon will receive commission, but not affiliate who actually invited referral. I was searching for solution but its probably MLM issue, not AffiliateWP. Could there be some solution? Maybe some php snippet? How to make referrers target parent affiliate but not random affiliate with dynamic coupon? Or make coupon invalid in such cases?
      Hope I am clear with it.

Viewing 3 reply threads
  • You must be logged in to reply to this topic.