[ ] Edit and finalize draft for publishing (remove draft label, add draft-finalized label)
[ ] Assign Issue to yourself and create Markdown file (remove draft-finalized label, add pending)
[ ] Project Lead: Review and Publish KB Article (remove pending label, add published label)
title: How can I offer a Free Registration with Access Code?
categories: Questions
tags: mu-plugins-hacks, tricks, giftredemption-codes, pro-forms, custom-capabilities
author: kristineds
github-issue: https://github.com/websharks/s2member-kb/issues/#
Additional TODOs
[ ] Insert screenshots
This is a work in progress.
I want people to get free access to my exclusive content (via promo code). I don't want to charge any fee, just allow people to enter their code and create an account.
You could set this up by generating a Paypal (Buy Now) Pro-Form and applying a coupon code that gives your customers 100% discount which will make it free and give them access to your exclusive content
Generate Pro-Form Coupon Code
Go to: WordPress Dashboard → s2Member → Pro Coupon Codes → Pro Coupon Codes Configuration
Add a Coupon code called "exclusive" (or any coupon code name you prefer) with 100% discount. Save All Changes.
To give specific users access to exclusive content, you’ll want to give those pages specific Custom Capabilities and then assign those users the Custom Capabilities for the pages you want to give them access to. Please see this video for more on Custom Capabilities. To assign those ccaps to specific users, this could be done by integrating [s2If /] (Simple Shortcode Conditionals) into your content.
Restrict content using Custom Capabilities (ccaps) and [s2If /] conditionals
To automatically assign new users one or more Custom Capabilities, you simply add those Custom Capabilities to the ccaps=”” attribute in your Paypal (Buy Now) Pro-Form shortcode. When the user signs up with that Paypal (Buy Now) Pro-Form, they’ll automatically get those Custom Capabilities and therefore have access to the pages restricted to them.
Generate Paypal (Buy Now) Pro-Form shortcode
Go to: WordPress Dashboard → s2Member → Paypal Pro-Forms → Forms For Level #1 Access
On the dropdown selection, you could choose "PayPal Pro (Buy Now): One Time (for lifetime access, non-recurring, no trial)". This depends if you want on how long you want your users to access the exclusive content
Add the new Custom Capability exclusive or edit the attribute ccaps="exclusive" on the Pro-Form shortcode
On the generated shortcode, set accept_coupons="1". You could also set it to accept="paypal" as to not confuse your users with entering their credit card information.
KB Article Creation Checklist
draft
and eitherquestions
ortutorials
draft
label, adddraft-finalized
label)draft-finalized
label, addpending
)pending
label, addpublished
label)Additional TODOs
This is a work in progress.
You could set this up by generating a Paypal (Buy Now) Pro-Form and applying a coupon code that gives your customers 100% discount which will make it free and give them access to your exclusive content
Generate Pro-Form Coupon Code
To give specific users access to exclusive content, you’ll want to give those pages specific Custom Capabilities and then assign those users the Custom Capabilities for the pages you want to give them access to. Please see this video for more on Custom Capabilities. To assign those
ccaps
to specific users, this could be done by integrating[s2If /]
(Simple Shortcode Conditionals) into your content.Restrict content using Custom Capabilities (
ccaps
) and[s2If /]
conditionalsTo automatically assign new users one or more Custom Capabilities, you simply add those Custom Capabilities to the
ccaps=””
attribute in your Paypal (Buy Now) Pro-Form shortcode. When the user signs up with that Paypal (Buy Now) Pro-Form, they’ll automatically get those Custom Capabilities and therefore have access to the pages restricted to them.Generate Paypal (Buy Now) Pro-Form shortcode
exclusive
or edit the attributeccaps="exclusive"
on the Pro-Form shortcodeaccept_coupons="1"
. You could also set it toaccept="paypal"
as to not confuse your users with entering their credit card information.If you want to extend this further, you can use a
success=""
attribute that will redirect users to a Thank you page after they sign up on your Membership page. See: http://s2member.com/kb-article/creating-a-registration-thank-you-page/#toc-3a5b356b