• Hi all, I apologize if this is the incorrect place to post. But looking for some help.

    [ Moderator note: moved to Fixing WordPress. Please do not use Developing with WordPress for these topics. ]

    I want to basically set up an affiliate tracking system, but not for sales- just sign ups through my landing page.

    I want to offer free content in a 3 part series where to see the next part of the series the visitor would need to share their “affiliate” link and generate 3 sign ups- then would get an automatic email upon the 3rd giving them the link to the next portion of content.

    Is there a plug-in available that this could be done through? I have tried WP Affiliate, and Affiliate WP and could not figure out a way through those to get it to work the way I wanted.

    Thanks in advance!

Viewing 1 replies (of 1 total)
  • You could do that with Affiliate WP by using their hooks.
    You could hook to new affiliate hook, and then get the number of referrals of that affiliate and if it was equal to 3 referrals you would send that email.

    Something like this:

    add_action( 'affwp_register_user', 'check_3_referrals', 10, 3 );
    add_action( 'affwp_auto_register_user', 'check_3_referrals', 10, 3 );
    
    function check_3_referrals( $affiliate_id = 0, $status = '', $args = array() ) {
    	$referrals = intval( affwp_get_affiliate_referral_count( $affiliate_id ) );
    	$affiliate_email = affwp_get_affiliate_email( $affiliate_id );
    	if( $referrals === 3 ) {
    		wp_mail( $affiliate_email, 'The subject', 'The message' );
    	}
    }
Viewing 1 replies (of 1 total)
  • The topic ‘Help Setting Up Referral Tracking’ is closed to new replies.