latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Level doesn't change after cancelation

Home Forums Community Forum Level doesn't change after cancelation

This topic contains 3 replies, has 2 voices. Last updated by  Cristián Lávaque 4 years, 1 month ago.

Topic Author Topic
Posted: Tuesday Nov 27th, 2012 at 2:34 am #32664

Hello there,

I am currently testing the plugin against PayPal’s sandbox. I canceled a paying member (level 1, 2 or 3) subscription using the associated PayPal Pro form. However, when I go to the dashboard and view the users who canceled, they still have their “old” subscription level.

Is this so because they still have some time left to access the site despite canceling the subscription (i.e. they subscribed for a month access with recurring fees on Nov 1st, and canceled on Nov 15th – still can access till the end of the month)?

If this is the explanation, then this brings up another question: what if I need to test whether the user is currently a paying subscriber or not, AFTER they canceled the subscription? As an example, in the “My Account” module, I would only want to show the “Cancel my subscription” link if the user is currently a paying member, and I do this using PHP conditionals. However, given the s2Member behavior described above, a subscriber that canceled his membership is still considered s2Member Level 2 (as an example) until the end of his subscription term. So using current_user_is(s2member_level2) yields true, and I will show the “Cancel my subscription” link despite that there is no longer a subscription to cancel…

So – is there a way to test whether a user is still considered a paying member, however his subscription status is “canceled”? this will be a great help for me.

TIA.

List Of Topic Replies

Viewing 3 replies - 1 through 3 (of 3 total)
Author Replies
Author Replies
Posted: Tuesday Nov 27th, 2012 at 7:46 am #32691

Is this so because they still have some time left to access the site despite canceling the subscription

That’s correct. Please read the documentation here: [hilite path]Dashboard -› s2Member® -› PayPal® Options -› Automatic EOT Behavior[/hilite]

So – is there a way to test whether a user is still considered a paying member, however his subscription status is “canceled”? this will be a great help for me.

You can check if he has an EOT time set, subscriptions that are still going won’t have it yet. http://www.s2member.com/codex/stable/s2member/api_functions/package-functions/#src_doc_get_user_field%28%29

[hilite pre_code]
$s2member_auto_eot_time = get_user_field ("s2member_auto_eot_time"); # Auto EOT-Time for the current User ( when applicable ).
[/hilite]

I hope that helps. :)

Posted: Tuesday Nov 27th, 2012 at 7:53 am #32693

Fantastic! Thanks for your help!

Posted: Wednesday Nov 28th, 2012 at 6:18 am #32755

Glad I could help. :)

Viewing 3 replies - 1 through 3 (of 3 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.