From 9fec89f65cd274f0a5410ac7d1754669cdf673fa Mon Sep 17 00:00:00 2001 From: campi Date: Wed, 5 Apr 2023 19:50:32 +0200 Subject: [PATCH] added shows radiomanifest feed --- admin/add_broadcast_page.php | 3 ++- feeds/radiomanifest-shows.php | 35 +++++++++++++++++++++++++++++++++++ inc/add-show-feed.php | 15 +++++++++++++++ radio-wombat-toolkit.php | 2 ++ 4 files changed, 54 insertions(+), 1 deletion(-) create mode 100644 feeds/radiomanifest-shows.php create mode 100644 inc/add-show-feed.php diff --git a/admin/add_broadcast_page.php b/admin/add_broadcast_page.php index cbb2816..9459454 100644 --- a/admin/add_broadcast_page.php +++ b/admin/add_broadcast_page.php @@ -95,7 +95,8 @@ function orari_dirette_input($post)
+ + 'broadcast', + 'numberposts' => -1, + 'orderby' => 'modified' +); + +$broadcasts = get_posts($post_options); + +foreach ($broadcasts as $post) { ?> + + <?php echo $post->post_title; ?> + + + post_title; ?> + ID ?> + + ID); ?> + post_name); ?> + + + + + diff --git a/inc/add-show-feed.php b/inc/add-show-feed.php new file mode 100644 index 0000000..8bfe73d --- /dev/null +++ b/inc/add-show-feed.php @@ -0,0 +1,15 @@ + diff --git a/radio-wombat-toolkit.php b/radio-wombat-toolkit.php index 02fdd70..96ede0e 100644 --- a/radio-wombat-toolkit.php +++ b/radio-wombat-toolkit.php @@ -35,6 +35,7 @@ function add_broadcast_taxonomy($args) ); wp_insert_term('Trasmissioni', 'category', $args); } + flush_rewrite_rules(); } foreach (glob(plugin_dir_path(__FILE__) . 'admin/*.php') as $file) { @@ -48,3 +49,4 @@ foreach (glob(plugin_dir_path(__FILE__) . 'inc/*.php') as $file) { foreach (glob(plugin_dir_path(__FILE__) . 'shortcodes/*.php') as $file) { include_once $file; } +