The Must Have for WordPress
The Must Have for WordPress
×
  • Home
December 5, 2019
WordPress

Add WordPress images to the RSS feed

by Martin Jost
No comments
1 min Reading Time
151 Views
5 Score
3 Likes
Share on Facebook Tweet on Twitter Share on Linkedin Pin on Pinterest Send via E-Mail Send via WhatsApp

By default, if you have enabled the WordPress RSS feed, images will not be included in the RSS feed. However, it makes sense to include a post image in the RSS feed.

For example, internet portals read a RSS feed of a website to display the title and text of a post. Often a field for the post image is also displayed.

How do I add images to the RSS feed?

The following code snippet makes it easy to automatically include your post image into the WordPress RSS feed. Paste this code, eg. in the functions.php file of your theme:

You can define another image size as follows:

You can also define an individual image size for the images that are now included in the RSS feed. Simply change the existing thumbnail name “thumbnail” to another image size.

For a large image size, use “large” or “full” instead, like the following example:

It works? You can check this by visiting to the RSS feed URL https://your-domain.com/feed/ of your WordPress website.

Last updated: December 5, 2019

Add WordPress images to the RSS feed Score: 5 / 5 (3votes)
Share on Facebook Tweet on Twitter Share on Linkedin Pin on Pinterest Send via E-Mail Send via WhatsApp
The Author
Published by
Martin Jost

View all posts by Martin Jost

Related Posts
G
PHP Get the current WordPress URL

In some cases, it may be necessary to get the current WordPress URL of where the user is current ...

Read More
A
WordPress Add custom classes to the WordPress BODY tag

Anyone who develops their own theme with a customizable layout or settings a theme needs to add ...

Read More
A
WordPress Anonymize IP address of WordPress comments

In the context of the European privacy policy regulations some regulations for web page owners a ...

Read More
Read more
C
Previous Post
Custom image sizes for your WordPress theme
R
Next Post
Remove the URL field in the WordPress comments form
Leave a Reply Cancel reply

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

  • Imprint
  • Privacy Policy
© 2016-2021 - wphave - The Must Have for WordPress
Login

Lost your password?

RequiredEssential cookies enable basic functions and are necessary for the proper functioning of the website.
  • Name: Cookie Status
  • Provider: Owner of this website
  • Purpose: Is necessary to check whether the user's web browser allows cookies.
  • Privacy Policy: https://wphave.com/privacy-policy/
  • Cookie Name(s): cookie_status
  • Duration: 1 Minute
  • Name: Cookie Consent
  • Provider: Owner of this website
  • Purpose: Is necessary to check whether the user agrees to allow opt-in cookies or not.
  • Privacy Policy: https://wphave.com/privacy-policy/
  • Cookie Name(s): cookieconsent_analytics, cookieconsent_marketing, cookieconsent_status
  • Duration: 1 Year
  • Name: Like Button
  • Provider: Owner of this website
  • Purpose: Is necessary to check whether the user has already gave a like for a specific post.
  • Privacy Policy: https://wphave.com/privacy-policy/
  • Cookie Name(s): like_btn_{POST_ID}
  • Duration: 21 Days
  • Name: Post Rating
  • Provider: Owner of this website
  • Purpose: Is necessary to check whether the user has already rate a specific post.
  • Privacy Policy: https://wphave.com/privacy-policy/
  • Cookie Name(s): rating_{POST_ID}
  • Duration: 7 Days
AnalyticsStatistics cookies collect information anonymously. This information helps us to understand how our visitors use our website.
  • Name: Google Analytics
  • Provider: Google LLC
  • Purpose: Google cookie for website analysis. Generates statistical data on how the visitor uses the website.
  • Privacy Policy: https://policies.google.com/privacy
  • Cookie Name(s): _ga, _gat, _gid
  • Duration: 2 Years