Normalize

// Add custom styles function add_custom_style_normalize() { wp_register_style( ‘the-new-normal’, ‘https://github.com/sarahschopick/the-new-normal.css/blob/1f917841c3a1382d644952dcaefb67e947467e22/the-new-normal.css’, array(), ‘1.0.0’ ); wp_enqueue_style( ‘the-new-normal’ ); } add_action( ‘wp_enqueue_scripts’, ‘add_custom_style_normalize’ );Continue reading

Show Wholesale Prices Text In Single Product Page For Wholesale Role Customers

/** * First Remove The Existing Pricing Filter So That It Will Be Available To All Users */ add_action(‘init’, ‘remove_existing_pricing_html’, 10); function remove_existing_pricing_html() { global $wc_wholesale_prices; remove_filter(‘woocommerce_get_price_html’, [$wc_wholesale_prices->wwp_for_non_wholesale_customer,’add_click_wholesale_price_for_non_wholesale_customers’], 10 ); } /** * Include Pricing HTML for all users */…Continue reading

Countdown

/* Import Playfair Display font from Google Fonts */ @import url(‘https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&display=swap’); /* Ensure consistent box model */ .countdown-container-custom, .countdown-segment-custom { box-sizing: border-box; } /* Main Container Styling */ .countdown-container-custom { text-align: center; padding: 40px 15px; background-color: #1a1a1a; background-image: url(‘https://lightsatthefair.com/wp-content/uploads/sites/5/2025/07/d6fb9991-6832-4b5c-bbfb-8029f85998e2-1024×676.png’); background-size:…Continue reading

Sticky Posts on Category Pages (copy)

add_action(‘pre_get_posts’, function($query) { if (!is_admin() && $query->is_main_query() && is_category()) { $sticky_posts = get_option(‘sticky_posts’); if (!empty($sticky_posts)) { add_filter(‘posts_orderby’, function($orderby, $query) use ($sticky_posts) { if (!is_admin() && $query->is_main_query() && is_category()) { global $wpdb; $sticky_list = implode(‘,’, array_map(‘intval’, $sticky_posts)); return “FIELD({$wpdb->posts}.ID, {$sticky_list}) DESC,…Continue reading

Keep All Checkout Data in WooCommerce Session

add_action( ‘woocommerce_checkout_update_order_review’, ‘bbloomer_save_checkout_values’, 9999 ); function bbloomer_save_checkout_values( $posted_data ) { parse_str( $posted_data, $output ); WC()->session->set( ‘checkout_data’, $output ); } add_filter( ‘woocommerce_checkout_get_value’, ‘bbloomer_get_saved_checkout’, 9999, 2 ); function bbloomer_get_saved_checkout( $value, $index ) { $data = WC()->session->get( ‘checkout_data’ ); if ( ! $data…Continue reading