Page 1 of 1

How to know the membership expiration date of a user?

PostPosted: November 26th, 2011, 8:48 pm
by mohsintheone
Hello Support :)

We have an yearly membership system on our website.. We have a PAYPAL Pay Now button, created by S2member..

I need to know that; is there a way, I could see that when the membership of a member is ending?

I hope that you would unnderstand my meaning?? Please let me know, if you require any further information to understand my problem.. Thanks

Looking Forward,

Mohsin

Re: How to know the membership expiration date of a user?

PostPosted: November 28th, 2011, 2:25 am
by Cristián Lávaque
Hi Mohsin. Currently, s2Member doesn't notify of coming expirations, but this is something we're working to add soon.

Re: How to know the membership expiration date of a user?

PostPosted: November 29th, 2011, 10:35 am
by mohsintheone
Thanks as always Cristian, for your quick reply :)

I hope that you people will soon get it done (very useful).. By the way; that means, I will have to go manually to see the status of each member?

Actually, I have set the EOT behavior to "Automatically change the user status to Subscriber".. On the day of EOT, S2member turns the user from S2member Level 2 to Subscriber.. And the registration date gets reset to the date of EOT..

So I would like to know that; Is there an easy way to get a list of the actual registration date, when user actually registered? So we can see that how many memberships are expired..

Hope you would understand the above..

Thanks & Looking Forward,

Mohsin

Re: How to know the membership expiration date of a user?

PostPosted: December 1st, 2011, 8:52 pm
by Cristián Lávaque
Would these help you? WP Admin -> s2Member -> API / Scripting -> s2Member Content Dripping -> Very Advanced

Here is the function documentation for PHP/WordPress® developers:

* Function: s2member_paid_registration_time ($level, $user_id); // returns a Unix timestamp.

The $level argument is optional. It defaults to the first/initial Paid Registration Time, regardless of Level#.
Or you could do this: s2member_paid_registration_time("level1"); which will give you the Registration Time at Level #1.
If a User/Member has never paid for Level #1 ( i.e. they signed up at Level#2 ), the function will return 0.

The argument $user_id defaults to the current user that is logged in.

Here are some examples:

Code: Select all
<?php
$time 
s2member_registration_time (); // ... first registration time ( free or otherwise ).
$time s2member_paid_registration_time (); // ... first "paid" registration and/or upgrade time.
$time s2member_paid_registration_time ("level1"); // ... first "paid" registration or upgrade time at Level#1.
$time s2member_paid_registration_time ("level2"); // ... first "paid" registration or upgrade time at Level#2.
$time s2member_paid_registration_time ("level3"); // ... first "paid" registration or upgrade time at Level#3.
$time s2member_paid_registration_time ("level4"); // ... first "paid" registration or upgrade time at Level#4.
?>