Skip to content

Instantly share code, notes, and snippets.

/feeds.php
Created Jan 20, 2016

Embed
What would you like to do?
<?php
// Die totale Abschaltung der RSS-Feeds
function ah_disable_feed() {
wp_die( __('Kein Feed verfügbar. Bitte besuchen Sie unsere <a href="'. get_bloginfo('url') .'">Startseite</a>!') );
}
add_action('do_feed', 'ah_disable_feed', 1);
add_action('do_feed_rdf', 'ah_disable_feed', 1);
add_action('do_feed_rss', 'ah_disable_feed', 1);
add_action('do_feed_rss2', 'ah_disable_feed', 1);
add_action('do_feed_atom', 'ah_disable_feed', 1);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.