function pj_databank_meta_grid() { if (!is_single()) return ”; return ‘ Category: Databank Entry Source: Popcorn Jedi Status: Active Transmission ‘; } add_filter(‘post_thumbnail_html’, function($html) { if (is_single()) { return $html . pj_databank_meta_grid(); } return $html; });Continue reading
function pj_databank_breadcrumbs() { if (!is_single()) return; echo ‘ Path: Popcorn Jedi / Databank ‘; } add_action(‘loop_start’, ‘pj_databank_breadcrumbs’, 20);Continue reading
/** * ACF-productlabel tonen. */ function ld_product_label() { if (!function_exists(‘get_field’)) { return; } global $product; if (!$product instanceof WC_Product) { return; } $label_text = get_field(‘label_tekst’, $product->get_id()); $kleur = get_field(‘achtergrondkleur’, $product->get_id()); if (!$label_text) { return; } if (!$kleur) { $kleur =…Continue reading
/* ========================================================= Vakantie-popup met instellingenpagina — WPCode PHP snippet – Menu-item “Vakantie popup” in het WordPress-menu – Sitenaam wordt automatisch uit de websitetitel gehaald – Start- en einddatum, teksten en icoon instelbaar – Testknop toont de popup direct in het…Continue reading
global $wc_wholesale_prices_premium; remove_filter( ‘option_woocommerce_tax_display_shop’, array( $wc_wholesale_prices_premium->wwpp_tax, ‘wholesale_tax_display_shop’ ) ); remove_filter( ‘option_woocommerce_tax_display_cart’, array( $wc_wholesale_prices_premium->wwpp_tax, ‘wholesale_tax_display_cart’ ) );Continue reading
add_post_type_support( ‘page’, ‘excerpt’ );Continue reading
add_action(‘template_redirect’, function() { if (!empty($_GET[‘mc_id’]) || is_singular(‘mc-events’)) { header(‘Location: ‘ . home_url(‘/upcomingevents/’), true, 301); exit; } }); add_action(‘init’, function() { global $wp_post_types; if (isset($wp_post_types[‘mc-events’])) { $wp_post_types[‘mc-events’]->public = false; $wp_post_types[‘mc-events’]->publicly_queryable = false; $wp_post_types[‘mc-events’]->exclude_from_search = true; } }, 99);Continue reading