I'm porting an existing product over to amember from another system. In the old system a single username can have multiple active subscriptions of this single product. When the user logs in, if they have multiple subscriptions, they are redirected to a page that lists them and allows them to choose which one they are logging into. It looks to me like amember allows a member to have multiple subscriptions to a single product and the unique identifier for each subscription is receipt_id. Is this correct? If so, when creating the account using {protect_plugin}_added how can I access the payment info to get the receipt_id? Looking at the eFront plugin as an example it looks like the payment_id used to be a parameter to {protect_plugin}_added but looking at the code and docs now that doesn't seem to be the case anymore. Any ideas are appreciated. Michelle
Michelle, You should use finish_waiting_payment hook instead http://manual.amember.com/Using_site.inc.php_and_hooks#finish_waiting_payment.28.24payment_id.29 Also you can't separate different subscriptions by receipt_id, for the same subscription after rebilling receipt_id will be different. You need to attach field to payment record and check it instead. What will be the ifference between subscriptions to the same product?
Hi Alexander, Thanks. Is the finish_waiting_payment hook called every time a subscription is activated? In our user database we have 2 tables that manage the subscriptions, the first one holds the username and password, the second one breaks down each subscription and contains the primary key of the first one. I can take the primary key of the subscription table and use it in amember if needed. Is there a way to tie a list of payments to a single subscription in amember? If there are 2 subscriptions that are billed monthly, how do I tell which payment ties to which subscription? Another way around this that I'd prefer not to use is to create a new product for each subsequent subscription and require the previous product to have the subsequent one active. Thanks, Michelle
Yes. This depends on payment system that you will use. Also what will be the difference between each subscription?
On the amember side, there won't be anything different between the subscriptions. The basic explanation of it is customer buys website hosting for $10 for the first site and then they pay an additional $5 for each site over and above the first one. We are planning on using website payments pro for the payment system. Thanks, Michelle
For Paypal's WPP you can check for $payment[data][PAYPAL_PROFILE_ID] it will be the same for all payments within single subscription.