Disable Iconic WDS Cookie Setting for Guest Users
add_filter( ‘iconic_wds_skip_cookie’, function() { return true; } );Continue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
add_filter( ‘iconic_wds_skip_cookie’, function() { return true; } );Continue reading
add_filter( ‘sptb_frequency_change_next_payment’, function( $bool, $user_id, $subscription ) { return false; }, 10, 3 );Continue reading
/** * Change wording of next payment date changed confirmation message via Toolbox for Subscriptions plugin from ‘shipment’ to ‘payment’ **/ add_filter( ‘jgtb_date_renewal_successful_message’, function( $message, $subscription ) { return ‘Next payment date has been successfully updated.’; }, 10, 2 );…Continue reading
add_filter( ‘jgtb_change_intervals’, function( $intervals, $subscription ) { foreach ( $intervals as $key => $interval ) { if ( ! in_array( $key, array( 1, 2 ) ) ) { // Numbers indicate which option (1 means weekly, 2 means every 2nd…Continue reading
add_filter( ‘woocommerce_product_description_heading’, ‘custom_change_description_heading_for_specific_categories’ ); function custom_change_description_heading_for_specific_categories( $heading ) { global $product; if ( ! is_product() || ! $product instanceof WC_Product ) { return $heading; } // Check if product has either ‘meals’ or ‘snacks’ category if ( has_term( [ ‘meals’,…Continue reading
add_filter( ‘manage_edit-shop_order_columns’, ‘bbloomer_add_new_order_admin_list_column’ ); function bbloomer_add_new_order_admin_list_column( $columns ) { $columns[‘item_count’] = ‘Item Count’; return $columns; } add_action( ‘manage_shop_order_posts_custom_column’, ‘bbloomer_add_new_order_admin_list_column_content’ ); function bbloomer_add_new_order_admin_list_column_content( $column ) { global $post; if ( ‘item_count’ === $column ) { $order = wc_get_order( $post->ID ); echo…Continue reading
add_shortcode(‘papa_macros_discount_message’, ‘papa_macros_discount_message_shortcode’); function papa_macros_discount_message_shortcode() { if ( ! function_exists(‘WC’) || ! WC()->cart ) { return ”; } $cart = WC()->cart; $manual_subtotal = 0; foreach ( $cart->get_cart() as $item ) { if ( ! isset($item[‘data’]) || ! is_object($item[‘data’]) ) continue; $price…Continue reading
if ( ! defined( ‘ABSPATH’ ) ) { return; } if ( ! class_exists( ‘WooCommerce’ ) ) { return; } if ( ! function_exists( ‘wcs_get_subscription’ ) ) { return; } function rd_aw_backfill_sub_original_delivery_meta( $workflow ) { if ( ! is_object( $workflow…Continue reading
if ( ! defined( ‘ABSPATH’ ) ) { return; } if ( ! function_exists( ‘rd_aw_wds_get_config’ ) ) { function rd_aw_wds_get_config() { $config = array( ‘cutoff_weekday_iso’ => 4, ‘cutoff_hour’ => 22, ‘cutoff_minute’ => 0, ‘delivery_weekdays_iso’ => array( 7, 1, 2, 3…Continue reading
if ( ! defined( ‘ABSPATH’ ) ) { return; } if ( ! class_exists( ‘WooCommerce’ ) || ! class_exists( ‘WC_Shipping_Zones’ ) ) { return; } if ( ! function_exists( ‘rd_get_order_shipping_zone_id’ ) ) { function rd_get_order_shipping_zone_id( $order ) { if (…Continue reading