s2Member Pro Forms ( via Custom Registration Field )
If you're using s2Member Pro with PayPal® Pro Forms, or Pro Forms for Authorize.Net® integration, the simplest way to accomplish this is with a Custom Registration Field that you configure with s2Member. In your Dashboard, under: s2Member -> General Options -> Custom Registration Fields, you can create a Checkbox field that is required, and in your description of this field, you can even include HTML code that may provide a link to your Terms/Conditions. ~So this is pretty simple, because your site is already integrated with s2Member Pro Forms. In other words, checkout occurs on your site! Very simple.
s2Member Payment Buttons ( i.e. PayPal® Standard, or similar )
In this case, checkout does NOT actually take place on your site. All you're doing is providing the potential Customer with a Payment Button, which sends them through the checkout process at PayPal®, or perhaps at ClickBank®, AliPay®, Google® Checkout, or another Payment Gateway that integrates with s2Member through the application of Payment Buttons.
In this case, you don't have s2Member Pro Forms working for you, so you'll need to be a little more creative. The code sample below will accomplish this for you. You'll need to make sure that you paste this into the HTML Tab of your Post/Page editor in WordPress®; otherwise the code will get corrupted by the Visual Editor. Be sure to replace [s2Member-PayPal-Button ... output="url" /] with your own ShortCode.
- Code: Select all
<form onsubmit="return false;">
<input id="our-terms-conds" type="checkbox" /> Yes, I agree to the Terms/Conditions.
<a href="[s2Member-PayPal-Button ... output="url" /]" onclick="if(!document.getElementById('our-terms-conds').checked){ alert('You MUST check the box that you agree.'); return false; }"><img src="https://www.paypal.com/en_US/i/btn/btn_xpressCheckout.gif" border="0" alt="PayPal®" /></a>
</form>
That part of your Shortcode must be configured manually when you use this technique.