How to fix US-CERT RSS feeds in WordPress

This has driven me absolutely nuts for the last 4 hours!

Apparently US-CERT is blocking WordPress headers/Wordpress user-agent from pulling their RSS feeds (or maybe not and this just happens to fix my issue). I’m not using the “Feedzy” plugin but this code snippet, when added to the bottom of the functions.php file for my particular WordPress theme, started showing the US-CERT RSS/XML feeds immediately.

REF: https://wordpress.org/support/topic/cert-us-rss-an-error-occured-for-when-trying-to-retrieve-feeds/

The code I added to the bottom of my functions.php file is here:
add_action( ‘http_headers_useragent’, ‘feedzy_change_user_agent’ );
function feedzy_change_user_agent() {
return SIMPLEPIE_USERAGENT;
}

Leave a Reply

Your email address will not be published. Required fields are marked *

one × 1 =