Podcast RSS Feed

add_action( ‘wp_enqueue_scripts’, function() { wp_add_inline_script( ‘jquery’, ‘ jQuery(document).on(“click”, “.uvri-tab-btn”, function() { jQuery(“.uvri-tab-btn”).removeClass(“active”); jQuery(“.uvri-tab-panel”).removeClass(“active”); jQuery(this).addClass(“active”); jQuery(“#” + jQuery(this).data(“tab”)).addClass(“active”); }); ‘ ); } ); function uvri_podcast_episodes_shortcode() { $year_season = array( 2023 => 1, 2024 => 2, 2025 => 3, 2026 => 4,…Continue reading

Campus Term Helpers

/** * BwC — Campus term helpers * [bwc_campus field=”school_name|location|url”] */ function bwc_campus_shortcode( $atts ) { $atts = shortcode_atts( array( ‘field’ => ‘school_name’, ‘link’ => ‘yes’, ‘new_tab’ => ‘yes’, ‘fallback’ => ”, ), $atts, ‘bwc_campus’ ); $terms = get_the_terms( get_the_ID(),…Continue reading

Disable Deactivation Links

add_filter( ‘plugin_action_links’, ‘disable_all_plugin_deactivation’, 10, 4 ); function disable_all_plugin_deactivation( $actions, $plugin_file, $plugin_data, $context ) { if ( get_current_user_id() !== 1 ) { // Replace 1 with your admin user ID unset( $actions[‘deactivate’] ); } return $actions; }Continue reading

GTranslate language switch – PROD LIBRARY

/* * Snippet #113: GTranslate language switch — auto reload * * GTranslate with url_structure=none sets the googtrans cookie client-side but * does not trigger a page reload. This means PHP-rendered content (e.g. the LTL * banner PDF link) and…Continue reading