How to add custom fields in rss feed

I have a custom field called argument. I’m trying to add it in RSS feed using the following code, but it’s not working. Am I missing something? function acf_feed($content) { if(is_feed()) { $post_id = get_the_ID(); $output=”<acfArgument>” . get_post_meta($post_id, “argument”, true) . ‘</acfArgument>’; $content = $content.$output; } return $content; } add_filter(‘the_content’,’acf_feed’); I added this function to … Read more

Change the RSS feed image

I want to customize this part of WordPress feeds: <image> <url>https://[example.com]/wp-content/uploads/cropped-logo-32×32.png</url> <title>My Site</title> <link>https://example.com</link> <width>32</width> <height>32</height></image> There is a similar question with a wrong answer here. Changing media settings in wp-admin does not work. I would like to change the image size or customize the entire part with a custom image URL for example. Thank … Read more

Custom RSS does not work for categories and tags

We have a custom RSS in our web. It works normally on Main page and post – https://www.kryptonovinky.cz/feed/spotify But in categories and tags it does not work https://www.kryptonovinky.cz/category/podcasty/feed/spotify redirect to https://www.kryptonovinky.cz/category/podcasty/feed Do you have any idea how to solve it? /* This code initializes the custom RSS Feeds for your website*/ add_action(‘init’, ‘customRSS’); function customRSS(){ … Read more

Sub-Sub-Blogs — creating and importing content into a custom sub-type

Description: The university radio station I volunteer at uses WordPress 3’s Network Mode for the entirety of its web content. It uses the format: Top-Level (.com/*) — Basic station information, links to feeds, etc. The main site. Subdomains (*.domain.com) — Station departments (I.e., “music”, “spoken word”, etc.) Program Top-Level Sub-Directory (.com/program/*) — Custom post type … Read more

Importing multiple RSS feed into WordPress and sorting them by date

I have found the following code to import feeds from multiple feeds and show them in wordpress. But, I want to sort all the combined feeds by date and show only 10. How can I do that? Thanks <?php $feed = fetch_feed(array(‘http://www.site1.com/feed/’, ‘http://www.site2.com/feed/’)); foreach($feed->get_items() as $item) { echo $item->get_title(); } ?> 1 Answer 1 Checking … Read more