Subscription control system

blsbox15

New Member
I am having a form which control subscription of a user, based on hourly, weekly, monthly and yearly subscription and having 'subscription_start_date' and 'subscription_end_date'.
How do I verify each users subscription against the 'subscription_end_date' field with the current time stamp. If the subscription_end_date and time occurs the system should automatically cancel the user from the subscription system service. Could some one please help?
 
Hi
What subscription service are you referring to, is it paypal or something else?
In general I would think you would need to use the scheduled task php plugin to look up the data in your subscriptions table and expire those uses who no longer had a valid subscription.
 
Hi

Say you have a database table called 'subscriptions' with a field 'subscription_end_date'.

I don't know what subscription service you are referring to so I can't comment on how to send information to that service, but for the sake of showing something meaningful, lets say the subscriptions table has a column 'active' which should be set to '1' when the subscription is active and '0' when it has expired.

You're scheduled task php code would need to look like this:
PHP:
$db = JFactory::getDbo();
$query = $db->getQuery(true);
$query->update('subscriptions')->set('active = 0')->where('subscription_end_date <= NOW()');
$db->setQuery($query);
$db->execute();

If you tell me what subscription service you are using perhaps I can give further help as to exactly what would need to be done.

Cheers
Rob
 
What we are actually looking is we want to implement a fully subscription management system where users can use their paypal account, credit card, etc and record all the transactions, invoices to db. Here we are using paypal form plugin,
Could you please provide all further guidelines to implement a fully functional subscription management system like fabrikar.com is using.
Thanks
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top