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.

API For Canceling

Home Forums Community Forum API For Canceling

This topic contains 3 replies, has 2 voices. Last updated by  Raam Dev 4 years, 3 months ago.

Topic Author Topic
Posted: Thursday Sep 13th, 2012 at 1:39 pm #25198

I am trying to hook when a user cancels or is deleted. What is the best way to do this?

I appears that using ws_plugin__s2member_during_paypal_notify_during_subscr_signup_w_update_vars doesn’t work when the IPN sends a cancel

List Of Topic Replies

Viewing 3 replies - 1 through 3 (of 3 total)
Author Replies
Author Replies
Posted: Thursday Sep 13th, 2012 at 11:43 pm #25238
Raam Dev
Username: Raam
Staff Member

Hi Thomas,

You might want to use one of the Automatic EOT hooks, perhaps ws_plugin__s2member_during_auto_eot_system_during_delete and/or ws_plugin__s2member_during_auto_eot_system_during_demote.

Posted: Friday Sep 14th, 2012 at 7:36 pm #25370

Doesn’t seem to work. I tried both of those in the mu-plugins and it didn’t fire when I deleted a user. Also if I move them from a role of say S2 Level 1 to just a normal Subscriber it doesn’t fire. If I use the WP hook of delete_user and delete them it fires. So what am I missing?

I have ws_plugin__s2member_during_paypal_notify_during_subscr_signup_w_update_vars and it fires when they sign up. If I cancel through PayPal it doesn’t fire off, yet the paypal-ipn.log shows the cancel triggering. So why doesn’t that work?

Posted: Sunday Sep 16th, 2012 at 11:08 pm #25531
Raam Dev
Username: Raam
Staff Member

Thomas,

Those two hooks I mentioned are for the s2Member Automatic EOT system, which means s2Member must process a deletion/demotion through the Auto EOT system for them to fire. Manually deleting a user or changing their role will not trigger the Automatic EOT System Hooks.

The easiest way to test those hooks is to create an account and then manually set an Automatic EOT Time (edit the users profile and enter in a date/time in the Automatic EOT Time field; click the little question mark for more info about the date/time format you need to use). When the Automatic EOT Time you entered in the account is reached, s2Member will demote/delete the account automatically through the Automatic EOT System and one of those two hooks I mentioned will trigger. (The configuration in Dashboard -› s2Member® -› PayPal® Options -› Automatic EOT Behavior will determine whether a demotion or deletion occurs.)

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.