Content-Type of RSS feed is application/octet-stream
-
Hi,
I recently upgraded to WordPress 4.5 and have a problem concerning RSS feeds generated by the Link Library plugin in version 5.9.12.16.
One of my link libraries is published as RSS feed, and the feed is then displayed in the WordPress RSS widget. This worked in WordPress 4.4.2 and fails since the upgrade to WordPress 4.5. The widget is empty for users, and shows the following message when logged in as admin:
A feed with an invalid mime type may fall victim to this error, or SimplePie was unable to auto-discover it.. Use force_feed() if you are certain this URL is a real feed.
Adding the following snippet to
functions.php
is a workaround that solves the problem:add_action('wp_feed_options', 'force_feed', 10, 1); function force_feed($feed) { $feed->force_feed(true); }
I used
wget
to find out the MIME types:- Feed created by link library:
Content-Type: application/octet-stream; charset=UTF-8
- Feed for posts created by wordpress:
Content-Type: application/rss+xml; charset=UTF-8
It seems that the mime type for the link library feed is not set correctly. Is it possible to fix this issue so that the workaround is no longer needed?
- Feed created by link library:
- The topic ‘Content-Type of RSS feed is application/octet-stream’ is closed to new replies.