Exclude Specific Products from Parent Category

/** * Exclude specific products from appearing in their parent category. */ add_action(‘woocommerce_product_query’, ‘exclude_specific_products_from_parent_category’); function exclude_specific_products_from_parent_category($q) { // Only apply this on the parent category archive page if (!is_product_category(‘telt-og-pavilloner’)) { // Replace with your parent category slug return; } //…Continue reading

Hide RD Theme Woo Additional Order Info Wrapping Column when No Additional Order Info Present

(function () { function rdToggleAdditionalOrderInfoColumn() { var container = document.getElementById(‘rd-additional-order-info’); if (!container) { return; } if (!container.querySelector(‘.awb-woo-order-additional-info’)) { container.style.display = ‘none’; } } if (document.readyState === ‘loading’) { document.addEventListener(‘DOMContentLoaded’, rdToggleAdditionalOrderInfoColumn); } else { rdToggleAdditionalOrderInfoColumn(); } })();Continue reading

Add a button to customer data

add_action( ‘woocommerce_admin_order_data_after_billing_address’, ‘custom_customer_history_search_button_blue’, 10, 1 ); function custom_customer_history_search_button_blue( $order ) { // Vásárló e-mail címének lekérése $customer_email = $order->get_billing_email(); if ( $customer_email ) { // A keresési URL összeállítása $search_url = admin_url( ‘edit.php?s=’ . urlencode( $customer_email ) . ‘&post_type=shop_order’ );…Continue reading

Untitled Snippet

document.addEventListener(“click”, (e) => { const pill = e.target.closest(“.rs-pill”); if (!pill) return; const row = pill.parentElement; row.querySelectorAll(“.rs-pill”).forEach(p => p.classList.remove(“active”)); pill.classList.add(“active”); });Continue reading

Replace APFWS Matching Product Notice

(function () { if (typeof window === ‘undefined’ || !document) return; // Exit if WooCommerce frontend scripts are not present. if (typeof window.wc_add_to_cart_params === ‘undefined’) return; // Exit if WooCommerce APFS is not present (guards by checking for its AJAX…Continue reading