Modify or Add To the Shortcode Display Template

As of WP RSS Aggregator version 4.0.9 and Excerpts & Thumbnails version 1.6.3, you can use the following filters:

  • wprss_single_feed_output - This filter is called after each feed item is added to the output
  • feed_output - This filter is called after all feed items are added to the output

These filters can be very useful if you want to add some text, custom HTML, separators or anything else.


1. Add “Hello World” after each feed item

add_filter( 'wprss_single_feed_output', 'my_function' );
* Add 'Hello World' after each feed item.
function my_function( $output ) {
    $output .= 'Hello World';
    return $output;

2. Add “That is all!” after all feed items are listed

add_filter( 'feed_output', 'my_function' );
* Add 'That is all!' after all feed items are listed.
function my_function( $output ) {
   $output .= 'That is all!';
   return $output;

How do I add this to my site?

Follow the step-by-step instructions below to add this filter to your WordPress site.

  1. Copy the code you need from above.
  2. Go to your WordPress site's dashboard.
  3. Go to Plugins > Add New.
  4. Search for Code Snippets, then install and activate the plugin.
  5. Once installed and activated, go to Snippets in your dashboard menu.
  6. Click on Add New.
  7. Add a Title, which could be the title of this article.
  8. Paste the code you copied in step 1 to the Code section.
  9. Add a Description or Tags if you wish to do so. It is not required.
  10. Click on Save Changes and Activate to save the filter and activate it.
    1. Or click on Save Changes to save the filter and activate it later.
  11. Your action or filter is now stored and active on your site.

Still need help? Contact Us Contact Us