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.

Using the S2Members Paypal buttons codes

Home Forums Community Forum Using the S2Members Paypal buttons codes

This topic contains 0 replies, has 1 voice. Last updated by  Joe Moya 3 years, 11 months ago.

Topic Author Topic
Posted: Friday Jan 18th, 2013 at 2:52 pm #38147
Joe Moya
Username: joemoya

I am using a database table to store my membership plans details.

In my post/page I use a [shortcode] for which the callback function runs a query on the table, extracts the values for the fields and returns the data to the post/page.

The problem is that if I use the “Resulting PayPal® Button Code” produced by S2Member, the Paypal page shows the following for the description (Terms and Amount are OK) :

Premium / description and pricing details here.
…php echo S2MEMBER_CURRENT_USER_VALUE_FOR_PP_ON0; …: … echo S2MEMBER_CURRENT_USER_VALUE_FOR_PP_OS0; …
… echo S2MEMBER_CURRENT_USER_VALUE_FOR_PP_ON1; … … echo S2MEMBER_CURRENT_USER_VALUE_FOR_PP_OS1; …

Obviously the problem is the php code which doesn’t get interpreted and instead is passed to Paypal in the description field.

If I use the WordPress shortcode produced by S2Member, I just get the entire shortcode displayed on the post/page.

Any idea on how to get around this issue?

For example:

function plans (plansname) {
$plandetails=$wpdb->get_results("SELECT * FROM  $wpdb->plans WHERE `name` = '$planname->name' ORDER BY `id` ASC");
foreach ($plandetails as $details) {
	echo $details-&gt;button . '<br>'; 
			}		
}		
 add_shortcode( 'theplans', 'plans' );

Thanks,
Joe

  • This topic was modified 3 years, 11 months ago by  Joe Moya.
  • This topic was modified 3 years, 11 months ago by  Joe Moya.
  • This topic was modified 3 years, 4 months ago by  Joe Moya.

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.