PriMoThemes — now s2Member® (official notice)

This is now a very OLD forum system. It's in READ-ONLY mode.
All community interaction now occurs at WP Sharks™. See: new forums @ WP Sharks™

Subscription EOT & Renew Actions

s2Member Plugin. A Membership plugin for WordPress®.

Subscription EOT & Renew Actions

Postby vkzawa » September 29th, 2011, 1:20 am

My scenario, I have given s2 subscribers to my website the ability to add posts to a custom post type.

What I would like to accomplish is:
1. To automatically set their posts to 'draft' status when their subscription ends or they cancel it.
2. Then if the user renews their subscription their posts get returned to a 'published' status.

I can write the code to set the post status in both cases, but what I need is the appropriate hooks to call to get this done. And can I determine the current user account that is being affected.

Do I use the action: ws_plugin__s2member_after_auto_eot_system to trigger the post status change to 'draft'? I have no clue which action will tell me when a user is renewed their account.

Thanks so much, this plugin is amazing. The Pro Authorize.net form work wonderfully.
-Vince
User avatar
vkzawa
Registered User
Registered User
 
Posts: 1
Joined: September 29, 2011

Re: Subscription EOT & Renew Actions

Postby Cristián Lávaque » October 1st, 2011, 3:35 am

Thanks for the kudos, Vince! Glad you're liking s2Member. :)

For your customization, maybe you can use the Notifications API. http://www.s2member.com/api-tracking-no ... ons-video/

Let me know if that helps.
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010


Return to s2Member Plugin

Who is online

Users browsing this forum: Google [Bot] and 3 guests

cron