Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
How do you create a subscription that ends on a fixed date? #218
KB Article Creation Checklist
Additional TODO list items go here.
A user wanted to know how to create a subscription that ended on a fixed date. I created a ProForm page that sold a subscription ending on 31 October 2015.
Note: You must use a plugin such as ezPHP to use PHP codes in your s2Member forms. Please see this s2Member KB article. I use ezPHP which allows me to use the
Use this PHP code on your page to assign the EOT date (it must be placed before the form shortcode -- I put mine at the top of the page):
Create a proforms shortcode using the s2Member control panel:
You will need to change the following attributes in your shortcode:
@jaswsinc @patdumond are you aware of these existing KB Articles related to this?
If this is not a duplicate of one of these (it doesn't appear to be--I think it's a slightly different scenario), you may want to link to both of those at the bottom of this KB Article ("See Also:").
The only thing that jumped out at me is that you said "you will need to enter this in the HTML tab of the WordPress editor" and it is actually labeled as "Text". Raam is right. This is not the same situation described in those KB articles, but is related, so a link to those articles would not be out of place.
I'll use this article as an example for the next time I need to write one, so it will be more detailed than the comment I left earlier. Closer to a finished product, in other words. Thanks for the opportunity to do this.
Edit 8 June: I just caught a typo here: Forcing an EOT to occur 31 October 2025 -- should be 2015.
Any chance we can get this finalized soon, I had another ticket wanting to know how to do this today.