wpsc_activated_subscription

Located in: paypal-pro.merchant.php, paypal-express.merchant.php

Functions that call this hook: process_gateway_notification()

Arguments Accepted: $cart_item_id, $merchant_object

Version Introduced: 3.8.9

Description: This action is triggered when IPN information of a recurring product is returned from PayPal.

Code in context:

[php firstline=”306″ highlight=”315″]

case ‘subscr_signup’:

case ‘subscr_payment’:

if ( in_array( $status, array( 2, 3 ) ) ) {

$this->set_transaction_details( $this->paypal_ipn_values[‘subscr_id’], $status );

transaction_results($this->cart_data[‘session_id’],false);

}

foreach ( $this->cart_items as $cart_row ) {

if ( $cart_row[‘is_recurring’] == true ) {

do_action( ‘wpsc_activate_subscription’, $cart_row[‘cart_item_id’], $this->paypal_ipn_values[‘subscr_id’] );

do_action(‘wpsc_activated_subscription’, $cart_row[‘cart_item_id’], $this );

}

}

break;

[/php]