Hide Selected Coupon Code (Name) in Notices + Classic Cart/Checkout Totals

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 ) { woocommerce_wp_checkbox( array( ‘id’ => ‘_rd_hide_coupon_code_public’, ‘label’ => __( ‘Hide coupon code’,…Continue reading

JS Tickera Auto Click (PassieVol)

// == Voelgoed Auto-Click Seating Map Button == // Priority: Vanilla JS -> jQuery (fallback) // Always ensures button is clicked once it appears, regardless of timing. (function() { var MAX_ATTEMPTS = 20; // Limit retries to avoid performance issues…Continue reading

Meta Pixel – InitiateCheckout Event

// Track InitiateCheckout event on checkout page add_action( ‘wp_footer’, ‘voelgoed_meta_pixel_initiate_checkout’, 20 ); function voelgoed_meta_pixel_initiate_checkout() { // Safety: don’t run in admin or during AJAX calls if ( is_admin() || wp_doing_ajax() ) { return; } // Must be checkout page if…Continue reading

Meta Pixel – Purchase Event

// Track WooCommerce Purchase event with Meta Pixel add_action(‘woocommerce_thankyou’, ‘voelgoed_meta_pixel_purchase’, 10, 1); function voelgoed_meta_pixel_purchase($order_id) { if (!$order_id) return; $order = wc_get_order($order_id); if (!$order) return; // Prevent duplicate tracking on page refresh if (get_post_meta($order_id, ‘_meta_pixel_tracked’, true)) return; // Build content_ids array…Continue reading

Meta Pixel – AddToCart Event

// Track AddToCart event with Meta Pixel add_action(‘wp_footer’, ‘voelgoed_meta_pixel_add_to_cart’); function voelgoed_meta_pixel_add_to_cart() { if (!function_exists(‘is_product’)) return; // Only on product pages if (!is_product()) return; global $product; if (!$product) return; ?>Continue reading

Meta Pixel – ViewContent Event

// Track ViewContent event on product pages add_action(‘wp_footer’, ‘voelgoed_meta_pixel_view_content’); function voelgoed_meta_pixel_view_content() { if (!function_exists(‘is_product’)) return; if (is_product()) { global $product; if (!$product) return; ?>Continue reading

Auto Complete Virtual Orders – Not EFT

/** * Auto-complete orders that contain ONLY virtual items, * but ONLY after payment is confirmed. * EXCLUDES EFT / Direct Bank Transfer (bacs). */ add_action( “woocommerce_payment_complete”, “vg_autocomplete_virtual_orders_after_payment”, 20 ); function vg_autocomplete_virtual_orders_after_payment( $order_id ) { if ( ! $order_id )…Continue reading

HosaEna Header Solid Transition (copy)

(function(){ const header = document.querySelector(‘.site-header’); function setSolidByScroll(){ if(!header) return; if(window.scrollY > 50){ header.classList.add(‘he-solid’); } else { header.classList.remove(‘he-solid’); } } window.addEventListener(‘scroll’, setSolidByScroll, {passive:true}); document.addEventListener(‘DOMContentLoaded’, setSolidByScroll); if(header){ header.addEventListener(‘mouseenter’, ()=> header.classList.add(‘he-solid’)); header.addEventListener(‘mouseleave’, ()=> setSolidByScroll()); } })();Continue reading

HosaEna Header Solid Transition (copy)

(function(){ const header = document.querySelector(‘.site-header’); function setSolidByScroll(){ if(!header) return; if(window.scrollY > 50){ header.classList.add(‘he-solid’); } else { header.classList.remove(‘he-solid’); } } window.addEventListener(‘scroll’, setSolidByScroll, {passive:true}); document.addEventListener(‘DOMContentLoaded’, setSolidByScroll); if(header){ header.addEventListener(‘mouseenter’, ()=> header.classList.add(‘he-solid’)); header.addEventListener(‘mouseleave’, ()=> setSolidByScroll()); } })();Continue reading