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
| /** | |
| * Snippet: Show strike-through price and "Save X%" for subscription products in Cart for WooCommerce | |
| * Add to theme functions.php or Code Snippets. | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| add_filter( 'fkcart_disable_strike_price_product_type', function ( $excluded_types ) { | |
| return array_diff( $excluded_types, [ 'subscription', 'variable-subscription', 'subscription_variation' ] ); |
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
| /** | |
| * Plugin Name: FKCart Tax Switch Suppress | |
| * Description: Hides Tax Switch dual price (incl/excl VAT) only in the cart icon/menu. | |
| * Keeps it active in the cart modal, product pages, etc. | |
| * Uses FKCart's native hooks - no backtrace. | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } |
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
| /** | |
| * If update_order_review returns and woocommerce_cart_hash cookie is not found → refresh checkout once. | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| add_action( 'wp_footer', 'keep_wc_session_refresh_script', 20 ); | |
| function keep_wc_session_refresh_script() { |
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
| /** | |
| * Plugin Name: WFACP + Razzi: Suppress Duplicate Login | |
| * Description: Removes Razzi's native login/coupon block on FunnelKit checkout (PHP compatibility). | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| add_action( 'wfacp_after_checkout_page_found', function () { |
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
| /** | |
| * Plugin Name: WFACP + Razzi: Suppress Duplicate Login | |
| * Description: Removes Razzi's native login/coupon block on FunnelKit checkout (PHP compatibility). | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| add_action( 'wfacp_after_checkout_page_found', function () { |
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
| // Load WR assets on all pages (plugin normally only loads on cart/checkout) | |
| add_action( 'wp_enqueue_scripts', function() { | |
| if ( is_admin() || ( function_exists( 'is_checkout' ) && is_checkout() ) ) { | |
| return; | |
| } | |
| if ( ! class_exists( '\FKCart\Includes\Data' ) || ! \FKCart\Includes\Data::is_cart_enabled( 'all' ) ) { | |
| return; | |
| } | |
| if ( ! defined( 'LWS_WOOREWARDS_VERSION' ) ) { |
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
| /** | |
| * Plugin Name: Order Bump - Show by Page ID | |
| * Description: Bump 1576 on page 10, bump 2910 on page 2906. | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| add_filter( 'wfob_filter_final_bumps', function( $final_bumps, $posted_data ) { | |
| $page_id = 0; | |
| if ( function_exists( 'wc_get_page_id' ) && function_exists( 'is_checkout' )) { |
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 | |
| if ( ! defined( 'ABSPATH' ) ) { | |
| exit; | |
| } | |
| $allowed_offer_ids = array( 13079277 ); | |
| $wfocu_offer_checkbox_callback = function() use ( $allowed_offer_ids ) { | |
| static $done = false; | |
| if ( $done ) { |
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
| if ( ! defined( 'ABSPATH' ) ) exit; | |
| add_filter( 'woocommerce_coupon_discount_amount_html', function( $h, $c ) { | |
| if ( ! $c || ! WC()->cart || (float) WC()->cart->get_coupon_discount_amount( $c->get_code(), WC()->cart->display_cart_ex_tax ) > 0 ) return $h; | |
| $code = strtolower( $c->get_code() ); $m = \Wdr\App\Controllers\ManageDiscount::class; | |
| $v = $m::$apply_as_coupon_values[ $code ]['value'] ?? null; | |
| if ( $v === null ) foreach ( $m::$applied_cart_coupon_discounts ?? [] as $x ) { if ( strtolower( $x['name'] ?? '' ) === $code ) { $v = $x['value']; break; } } | |
| if ( $v === null && count( WC()->cart->get_applied_coupons() ) === 1 ) { | |
| $v = 0; |
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
| add_filter( 'fkcart_reward_total', 'fkcart_rewards_total_fallback', 999, 3 ); | |
| function fkcart_rewards_total_fallback( $total, $calculation_mode, $front ) { | |
| if ( 'total' !== $calculation_mode ) { | |
| return $total; | |
| } | |
| if ( is_null( WC()->cart ) || WC()->cart->is_empty() ) { | |
| return $total; | |
| } | |
| // Only fallback when total is 0 or negative but cart has items |
NewerOlder