MemberPress: Limit Phone Number Digits

function mepr_limit_phone_digits( $errors ) { $phone = isset( $_POST[‘mepr_phone_number’] ) ? sanitize_text_field(trim($_POST[‘mepr_phone_number’])) : ”; // Remove all non-numeric characters from the phone number. $phone = preg_replace(“/[^0-9]/”, “”, $phone); // Check if phone digits equal 11 if (strlen($phone) != 11) {…Continue reading

MemberPress: Override Description for All Payment Methods on Click

jQuery(document).ready(function($) { // Listen for a click event on the payment method label $(document).on(‘click’, ‘.mepr-payment-option-label’, function() { // Loop through all payment method description elements and update the text $(‘.mepr-payment-method-desc-text’).each(function() { var $this = $(this); var newText = ‘New text…Continue reading