• Contact
  • Privacy Policy
  • About Us
Tech News, Magazine & Review WordPress Theme 2017
  • Reviews
  • Tech and Gadgets
  • How To
  • Internet
  • Tech Explained
  • Misc
No Result
View All Result
  • Reviews
  • Tech and Gadgets
  • How To
  • Internet
  • Tech Explained
  • Misc
No Result
View All Result
Shroudgeeks.com
No Result
View All Result

How to add Caption to WordPress Featured Image – Includes Custom Theme

Van Phelps by Van Phelps
July 15, 2023
Home How To

WordPress is a feature-rich platform that provides you so many features. One such feature is the caption for featured images. There can be situations when you don’t find any options to add captions. What will you do in such cases? This article will teach you to add captions for featured images. So be here till the end.

Table of Contents

Toggle
  • What is a caption?
  • Why is it Essential to add a Caption to WordPress Featured Image?
  • Show Caption Under WordPress Featured Image From Dashboard
  • What if Your Theme Doesn’t Support it?

What is a caption?

The simple answer to this question is the image information that you want to show to the user. In WordPress, you cannot edit the featured image on the post edit page. Whereas for other photos, you can add links just like adding them to text.

Why is it Essential to add a Caption to WordPress Featured Image?

At this moment, you know, a caption is a piece of information about an image. And it is essential to give credit to the image you are using. In case the image caption feature is absent, how will you give credit to the site? In addition, how will you provide information to the end user? You need to add support to your current theme.

Read, Developer Options Android – Everything You Need to Know

Show Caption Under WordPress Featured Image From Dashboard

This method is straightforward. But it works only if your current theme supports this feature. Fortunately, most themes support this feature. With that said, let us understand how you can add captions to your featured image. When you add a featured image from media in WordPress, you get the option to edit image information. From here, you can edit or add image information such as title, caption, and description.

Add caption to WordPress Featured Image

But the problem is when you set your featured image. It will only show the image on the screen. Talking about showing the picture, it depends on the theme you are using. In case your theme doesn’t support it, it will not how. However, I will cover the solution for not supporting themes also.

What if Your Theme Doesn’t Support it?

If your current theme doesn’t support featured image captions, you need to add them. For this, you need to figure out the file, which is the file containing the feature image. Once you find that file, you need to add the below-given code. It will add the needed support. If you liked this guide you may also like our guide Intel Vs. AMD. With that said, we have completed the guide.

<?php if (get_post(get_post_thumbnail_id())->post_excerpt) { // search for if the image has caption added on it ?>
    <span class="featured-image-caption">
        <?php echo wp_kses_post(get_post(get_post_thumbnail_id())->post_excerpt); // displays the image caption ?>
    </span>
<?php } ?>


Van Phelps

Van Phelps

Next Post
YPhone Review

YPhone Review - The iPhone for Your Children

Leave a Reply Cancel reply

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

Recommended.

MSI Mystic Light

MSI Mystic Lights – How to Download, use Effects and More?

July 22, 2023
Difference between a gaming laptop and a regular laptop

Difference Between a Gaming Laptop and a Regular Laptop – Complete Guide

July 21, 2023

Trending.

No Content Available
Shroudgeeks.com

Shroudgeeks is the place for all tech enthusiasts. Here we bring everything related to tech to your fingertips.

Categories

  • How To
  • Internet
  • Reviews
  • Tech And Gadgets
  • Tech Explained

Recent News

q7 smartwatch

Q7 Smartwatch – A Brief Review and Setup Guide 2023

September 17, 2023
".6"" acer kg241q"

“.6″” acer kg241q” – A Value For Money Budget Monitor

September 7, 2023
  • Contact
  • Privacy Policy
  • About Us

© 2023 Shroudgeeks.com All Rights Reserved

No Result
View All Result
  • Reviews
  • Tech and Gadgets
  • How To
  • Internet
  • Tech Explained
  • Misc

© 2023 Shroudgeeks.com All Rights Reserved