This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // DO NOT COPY THIS LINE, it will trigger a fatal error. Copy from below please! | |
/* | |
* Bcc admin on specific email templates only | |
* more then one can be added like this: | |
* $headers[] = "Bcc:" . "otheremail@domain.com,anotheremail@domain.com"; | |
* You can change the conditional to check for a certain $email->template or some other condition before adding the BCC. | |
* Please add the below code to your site by following this guide: | |
* https://www.paidmembershipspro.com/how-to-add-code-to-wordpress/ | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not copy this line | |
/** | |
* This recipe makes all billing fields on the checkout page not required | |
* | |
* Note: Make sure your Gateway doesn't require these fields. | |
* | |
* You can add this recipe to your site by creating a custom plugin | |
* or using the Code Snippets plugin available for free in the WordPress repository. | |
* Read this companion article for step-by-step directions on either method. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not copy this line | |
/** | |
* Add bcc for PMPro admin emails | |
* Follow this guide to add custom code to your site - https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
function my_pmpro_email_headers_admin_emails($headers, $email) { | |
// bcc emails already going to admin_email | |
if (strpos($email->template, '_admin') !== false) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // Do not copy this line | |
/** | |
* Add user fields using code with multiple headers. | |
* This example will add a Business, Study and Laptop Information section to your checkout and profile pages | |
* | |
* title: Add user fields using code. | |
* collection: user-fields | |
* category: custom-fields | |
* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not copy this line | |
/* | |
* This recipe would always show the renew link on the membership account page for the specified levels on line 13 | |
* Add the below code to your PMPro Customizations Plugin: | |
* https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
// always show renew links for certain levels if the member already has that level. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Enables comments for User Pages | |
function enable_comments_for_user_pages($postdata, $user, $level) | |
{ | |
$postdata['comment_status'] = 'open'; | |
return $postdata; | |
} | |
add_filter('pmpro_user_page_postdata', 'enable_comments_for_user_pages', 10, 3); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // Do Not Copy This Line | |
/** | |
* This recipe will help you change text on the checkout paid in PMPro | |
* You can add this recipe to your site by creating a custom plugin or using the Code Snippets plugin available for free in the WordPress repository. | |
* Read this companion article for step-by-step directions on either method: https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
*/ | |
// paste content from below this line | |
function pmproc_change_my_text( $translated_text, $text, $domain ) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not copy this line | |
/* | |
Plugin Name: Paid Memberships Pro - Australia GST | |
Plugin URI: http://www.paidmembershipspro.com/wp/pmpro-australia-gst/ | |
Description: Apply Australia GST to Checkouts with PMPro | |
Version: .1 | |
Author: Stranger Studios | |
Author URI: http://www.strangerstudios.com | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not copy this line | |
/** | |
* Change the "IMPORTANT!" confirmation text when using PMPro and the Email Confirmation Add On. | |
* Add this code into a custom plugin or code snippet. | |
* Be sure to change the translated lines below to the language and words you want. | |
* https://www.paidmembershipspro.com/how-to-add-code-to-wordpress/ | |
*/ | |
function my_pmpro_email_confirmation_text( $translated_text, $text, $domain ) { | |
// Ignore strings for other plugins. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // DO NOT COPY THIS LINE | |
/* See full article here please: https://www.paidmembershipspro.com/set-up-unique-membership-confirmation-pages-based-on-level/ | |
* Copy this into a PMPro Customizations Plugin: https://www.paidmembershipspro.com/create-a-plugin-for-pmpro-customizations/ | |
**/ | |
function my_pmpro_confirmation_url($rurl, $user_id, $pmpro_level) { | |
if(pmpro_hasMembershipLevel(2)) | |
$rurl = "https://online.9jacodekids.com/my-account/"; | |
elseif(pmpro_hasMembershipLevel(3)) |
NewerOlder