if ( ! defined( ‘ABSPATH’ ) ) { exit; } add_action( ‘cli_init’, function () { if ( ! defined( ‘RD_FF_API_KLAVIYO_PRIVATE_KEY’ ) || ! RD_FF_API_KLAVIYO_PRIVATE_KEY ) { WP_CLI::error( ‘RD_FF_API_KLAVIYO_PRIVATE_KEY is not defined.’ ); } WP_CLI::add_command( ‘rd ff-klaviyo-backfill’, function ( $args, $assoc_args…Continue reading
/** * 2. Calculate the exact Stripe Fee (2.9% + .30) if “Yes” is selected */ add_filter( ‘charitable_get_donation_amount’, function( $amount, $data ) { if ( isset( $data[‘cover_fee_choice’] ) && ‘yes’ === $data[‘cover_fee_choice’] ) { // Reverse math formula: (Amount +…Continue reading
/** * 1. Register the Required Yes/No Radio Field */ add_action( ‘init’, function() { if ( ! class_exists( ‘Charitable_Donation_Field’ ) ) return; $field = new Charitable_Donation_Field( ‘cover_fee_choice’, array( ‘label’ => __( ‘Would you like your donation to cover third-party credit…Continue reading
/** * 1. Register the Required Yes/No Radio Field */ add_action( ‘init’, function() { if ( ! class_exists( ‘Charitable_Donation_Field’ ) ) return; $field = new Charitable_Donation_Field( ‘cover_fee_choice’, array( ‘label’ => __( ‘Would you like your donation to cover third-party credit…Continue reading
if ( ! defined( ‘ABSPATH’ ) ) { exit; } // Retrieve Klaviyo Private Key add_filter( ‘frm_api_request_args’, function ( $arg_array, $args ) { if ( ! defined( ‘RD_FF_API_KLAVIYO_PRIVATE_KEY’ ) || ! RD_FF_API_KLAVIYO_PRIVATE_KEY ) { return $arg_array; } if ( empty(…Continue reading
/** * ============================================================================= * VOELGOED — META CONVERSIONS API (CAPI) — PURCHASE (SERVER-SIDE) * ============================================================================= * – Captures fbp/fbc + IP + UA at checkout into order meta * – Sends Purchase via Conversions API when order is PAID (processing/completed)…Continue reading
/** * ============================================================================= * META PIXEL BASE + MANUAL ADVANCED MATCHING (WooCommerce/WordPress) * Pixel ID: * ============================================================================= * IMPORTANT: * – Remove any other hard-coded Meta Pixel base code (to avoid duplicates). * – Only run this if you have…Continue reading
add_filter( ‘frm_validate_field_entry’, ‘rd_ff_block_existing_user_email’, 20, 3 ); function rd_ff_block_existing_user_email( $errors, $posted_field, $posted_value ) { // REQUIRED $form_id = 0; // Formidable form ID $email_field_id = 0; // Email field ID // OPTIONAL: meta-gated blocking $only_block_if_meta_match = true; $meta_key_to_check = ‘paying_customer’; $meta_value_to_block…Continue reading
if ( ! defined( ‘ABSPATH’ ) ) { exit; } if ( class_exists( ‘WooCommerce’ ) ) { add_action( ‘woocommerce_coupon_options’, ‘rd_wc_add_hide_coupon_code_field’, 10, 2 ); function rd_wc_add_hide_coupon_code_field( $coupon_id, $coupon ) { $current = get_post_meta( $coupon_id, ‘_rd_hide_coupon_code_public’, true ); woocommerce_wp_checkbox( array( ‘id’ =>…Continue reading