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.

Automatic Upgrades

Home Forums Community Forum Automatic Upgrades

This topic contains 5 replies, has 2 voices. Last updated by  Cristián Lávaque 3 years, 10 months ago.

Topic Author Topic
Posted: Friday Mar 1st, 2013 at 5:30 am #43455

Greetings,

I’m looking to set up a system that automatically upgrades peoples membership to the next level, up-to a maximum level we set. I know we could do something similar with content dripping, but this isn’t going to achieve the same thing we wish to do.

I’m curious to know if we’re able to use content dripping, to then upgrade membership over time. Something like this:

If Level #1 && Paid Membership for Level #1 >= 30 Days then

{ Upgrade to Level #2 using Php}

If Else Level #2 && Paid Membership for Level #2 >=  30 days then

{ Upgrade to Level #3 using PhP}

If Else Level #3 && Paid Membership for Level #3 >=  30 days then

{ Upgrade to Level #4 using PhP}

If this is at all possible, that would be great.

Please Note; We’re not looking to upgrade their monthly fee when they upgrade their membership level. We’re doing it purely as we wish to offer personalised content based on levels, rather then duration, and we’re looking to have people on different membership levels on different mailing lists.

List Of Topic Replies

Viewing 5 replies - 1 through 5 (of 5 total)
Author Replies
Author Replies
Posted: Saturday Mar 2nd, 2013 at 8:14 am #43592

Hey there.

Sure, you could do something like that.

See:
[hilite path]Dashboard -› s2Member® -› API / Scripting -› Content Dripping[/hilite]
Knowledge Base » Changing Roles/Capabilities via PHP

This would only affect their access, not their subscription. The subscription is handled by the payment gateway and the changes you make to the user role don’t affect it.

I hope that helps. :)

Posted: Saturday Mar 2nd, 2013 at 10:03 am #43615

In the example listed on that page, I see this section:

if (s2member_registration_time ($user->ID) <= $_10_days_ago)

Is is possible to input a Paid Registration Time rather then a Registration Time, so something like this:

if (s2member_paid_registration_time ($user->ID) <= $_10_days_ago)

Update:

After doing some testing with this, I was wondering if I could get some help in building this up to do exactly what I want, because a few issues have arisen from this.

Firstly, it is setting my Administration Account to the appropriate levels during the processing, and I was wondering if there is a way to prevent that.

Secondly, I was wondering if I could maybe have this done multiple times. So, every 3 months, the user is updated into the next level up to a maximum level.

We have 4 levels that we want people to go through, and on the 5th level we want them to stop being promoted every 3 months. Is this at all possible?

Posted: Monday Mar 4th, 2013 at 4:50 am #43686

Any update I can get on this matter?

Posted: Tuesday Mar 5th, 2013 at 12:22 pm #43794

Is it possible to get help with this matter? It is pretty vital to my website.

Posted: Wednesday Mar 6th, 2013 at 2:40 am #43834

After doing some testing with this, I was wondering if I could get some help in building this up to do exactly what I want, because a few issues have arisen from this.

For example, for the first upgrade from Level 1 to 2, it’d be something like this:

[hilite pre_code]
= 30) {
$user = new WP_User(S2MEMBER_CURRENT_USER_ID);
$user->set_role('s2member_level2');
}
?>
[/hilite]

There are useful s2Member constants (like [hilite mono]S2MEMBER_CURRENT_USER_PAID_REGISTRATION_DAYS[/hilite] and [hilite mono]S2MEMBER_CURRENT_USER_ID[/hilite] used above) documented here: [hilite path]Dashboard -› s2Member® -› API / Scripting -› PHP/API Constants[/hilite].

I hope that helps. :)

Viewing 5 replies - 1 through 5 (of 5 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.