WP Simple Pay: Facebook Payment Conversion Tracking

/** * @link https://library.wpcode.com/snippet/j57gg315/ */ add_action( ‘simpay_payment_receipt_viewed’, /** * Runs the first time the payment confirmation page is viewed. * * @param array $payment_confirmation_data */ function( $payment_confirmation_data ) { // Payment customer data (not used in this example). $customer =…Continue reading

WP Simple Pay: Add User Meta After Payment

/** * @link https://library.wpcode.com/snippet/qo9xxmjo/ * * @param \Stripe\Event $event Stripe Event. * @param \Stripe\Subscription|\Stripe\PaymentIntent $object Stripe Subscription or PaymentIntent */ function simpay_update_wp_user( $event, $object ) { $email_address = $object->customer->email; $wp_user = get_user_by( ’email’, $email_address ); // User cannot be found,…Continue reading

Remove Author Links

// Remove the author link from bio. add_filter( ‘wpex_post_author_bio_data’, function( $data ) { unset( $data[‘posts_url’] ); return $data; } ); // Remove the author link from code functions which display in post meta. add_filter( ‘the_author_posts_link’, function( $link ) { if…Continue reading

Show Left Sidebar Before Content on Mobile

add_action( ‘init’, function() { if ( function_exists( ‘wpex_content_area_layout’ ) && ‘left-sidebar’ === wpex_content_area_layout() ) { remove_action( ‘wpex_hook_primary_after’, ‘wpex_get_sidebar_template’ ); add_action( ‘wpex_hook_primary_before’, ‘wpex_get_sidebar_template’ ); } } );Continue reading