Page 1 of 1

S2M shortcodes outside WP

PostPosted: January 9th, 2012, 1:03 pm
by cassel
I know that s2M is a WP plugin, but i wonder if the shortcodes can be used outside the WP site itself. Here is where the question comes from.

Currently, s2M does not seem to handle the EOT too well for some types of memberships. I have had a product sold as "buy now" for a period of 6 months, after which i was hoping the EOT was going to be addressed. Since itis not, i thought i could simply use my MailChimp Autoresponder with a manually entered date of registration, and then, an auto-email would be sent, a couple of weeks before the end of the 6 months inviting them to now join the "monthly fee membership". I am thinking of making a particular "sale page" for that membership that is not available in the navigation where i would place the button to purchase that. In my autoresponder i would direct the member to that page where they could renew their membership (i know it is not exactly renewing but i hope it is still clear).

I think this would work BUT, in order to make it even easier on the members, i was wondering if there was a way to integrate the button directly into the email i will send. Is that something possible? It would definitely make things faster as the member would not have to go from the email to the site and then click, and could only click right from the email. Is that possible? Is it something that could be considered within the EOT question that is being addressed in the developement of the newest version?

Re: S2M shortcodes outside WP

PostPosted: January 11th, 2012, 12:51 pm
by Raam Dev
Hi Cassel,

It's definitely not possible to use WordPress/s2Member shortcodes in an email, as the email wouldn't have the WordPress framework necessary to turn the shortcode into the form or link that creates the button.

However, taking a step back, if you want to send your customer a link to join the monthly fee membership and you want that to happen with their existing s2Member account, you'll need to figure out how to automatically log them into s2Member/WordPress bypassing their username/password authentication and then send them to a page where they can click on a button to make the purchase (or just send them directly to the checkout page).

Automatic login from a link on an external site/email is not something currently supported by s2Member, so you'd need to find/build a plugin that adds that functionality. From a technical standpoint, it is possible, but it's also messy and prone to security holes.

Re: S2M shortcodes outside WP

PostPosted: January 11th, 2012, 8:07 pm
by cassel
I kind of thought that was going to be the case. I guess i will just make a "renewal" page and direct them with the link in the email. I might also make the content only accessible to logged in members so no "accidental visitors" get to it. Thanks.

Re: S2M shortcodes outside WP

PostPosted: January 12th, 2012, 5:26 pm
by Raam Dev
Sounds good. Let us know if you have any other questions. :)

Re: S2M shortcodes outside WP

PostPosted: January 15th, 2012, 3:36 pm
by cassel
As i am working on that page, i started with this logic:
if user is not logged in
- tell him he has to log in
if user is logged in but does not have the ccap for CourseA (available only for registered students of the course)
- tell him the renewal buttons are only available to current registered students of CourseA

However, i am facing another challenge: what if the user had his "first 6 months" period expired? At that point, the user does not have the ccap anymore, so is there a way to know if the user "had the ccap at any point in the past"?

Re: S2M shortcodes outside WP

PostPosted: January 16th, 2012, 10:12 pm
by Raam Dev
That's correct. Once their account is demoted to a Free Subscriber, their Custom Capabilities will be erased and you won't have any way of knowing what ccap's they had in the past. I can't think of an easy way around that.

Re: S2M shortcodes outside WP

PostPosted: January 16th, 2012, 10:17 pm
by cassel
Is there a way to get a "time sensitive" link, a bit like a download? I am thinking that if they past the "expiration date" for the ccap, they could email me and i would give them a different link that would be direct? something that would not stay valid too long in case someone finds it by accident?

Re: S2M shortcodes outside WP

PostPosted: January 16th, 2012, 11:02 pm
by Raam Dev
You can generate an access link to a Specific Post/Page WP Admin -> s2Member -> PayPal Buttons -> Specific Post/Page Access Links and set it to expire after a certain amount of time.

Re: S2M shortcodes outside WP

PostPosted: January 16th, 2012, 11:15 pm
by cassel
Cool. I will look into that. Thanks.