Log in

View Full Version : Paid Subscription Cancellation Question


vb_mp
10-07-2008, 08:38 AM
Hi,

I have a paid recurring subscription on my forum. When a user pays they are moved into a "Paid Subscriber" usergroup.

If they cancel their recurring subscription via PayPal, I would like to be able to move them back on Subscription expiration date to "Registered User" usergroup.

Does anyone have ideas how I can do this?

I don't want to move them back when the IPN comes in from PayPal when they cancel their subscription but rather on the date their existing subscription runs out.

Thank you,

vb_mp

firstimecaller
10-07-2008, 10:44 AM
I'm not sure I understand.... this happens automatically by the scheduled task 'subscriptions.'

./includes/cron/subscriptions.php , run once a day, by default

check that file, you'll see what it does

vb_mp
10-07-2008, 12:33 PM
Hm, it does contain the delete_user_subscription method call which in turn rearranges the usergroups.

while ($subscriber = $vbulletin->db->fetch_array($subscribers))
{
$subobj->delete_user_subscription($subscription['subscriptionid'], $subscriber['userid'], -1, true);
}

I will have to look into why it's not working for me, perhaps the cron is not being run.