FSM Custom Featured Image Caption

FSM Custom Featured Image Caption

Wordpress plugin

Install on Wordpress

App Details

This plugin allows adding custom captions to the featured images of the posts. It works with both Gutenberg and the classic editor.

That’s how it works:

  • If no caption is indicated, the plugin will display the generic caption defined in the Media Library.
  • If a caption is indicated, the plugin will display this caption instead of the generic caption defined in the Media Library.
  • If no caption is indicated and no legend exists in the Media Library, none will be displayed (obviously).

The plugin also allows to:

  • Hide the caption, either the original from the Media Library or the custom one.
  • Entirely hide the featured image in the public view, without having to de-attach it from the post.
  • Configure several options to modify the styles used in the caption.
  • Output the text of the caption anywhere in your theme using a custom function.
  • Output the featured image with caption inside your content with a shortcode.

For maintaining a semantic code, this plugin writes the caption in a <figcaption> label.

New in version 1.21: Compatibility with Divi themes. This is an experimental feature to allow the plugin to work with Divi, as many users requested. Note that it may not work for all layouts, and that since it replaces the function divi uses to show featured images, when enabled it may potentially cause problems with older versions of Divi or if the core theme is updated. As always, it may also be necessary to add custom css to your theme to show the captions the way you want

Format

The caption will adopt the format specified for the <figcaption> element and the wp-caption-text CSS class, which is common in WordPress themes.

Usage

The plugin works out of the box. To start using it, all you need to do is activate it and play with the new options in your edit page. For advanced users, you will found a special settings page for fine-tuning some details.

Go to Settings > FSM Custom Featured Image Caption to set up the CSS and HTML parameters:

  • CSS for caption text: Choose one of the options to modify the class/styles that will be used in the caption container (by default is wp-caption-text). Note that you can indicate more than one class separated with spaces.
  • Allow HTML code: Check it if you want to parse the caption text as HTML if you need the browser to parse HTML tags instead of showing them. Keep in mind that incorrect HTML code or orphan tags can break your layout.
  • Allow shortcodes: Check it if you want to parse the shortcodes present in the caption text. Note that if the shortcode returns HTML it will not be filtered, regardless of the “allow html code” option state; also, complex shortcodes output may alter your layout. When activated, you can write the shortcode you want to use in the caption box in the usual way, i.e. : Venetian landscape [myshortcode option1="text"]
  • Show image captions in lists: Disabled by default. Check if you want to show the caption when the featured image appears in lists, i.e. in a category page, in a widget with latest posts, etc. Note that some themes may add containers around the image (i.e. a link tag) witch can conflict with the aspect of the caption.
  • Enable compatibility with Divi themes: Disabled by default. Allows the plugin to work with Divi. Please read the description and the FAQ sections for more info about this option

Shortcode

We’ve added a shortcode that allows you to put the featured image (and it’s caption) in your page. Just write [FSM_featured_image] anywhere in the content edit box of your post or page to display it. You can also select the size of the image with the parameter “size”. Note that defined image sizes may differ between WordPress themes. The defaults are these: thumbnail, medium, medium_large, large and full.

By using the shortcode, the plugin will try to remove the featured image from your theme’s default position to prevent it from appearing twice. Anyway, this is as this is an experimental feature and results may fluctuate. It also will not appear in lists.

Note that the usage of the shortcode is not related to the “Allow shortcodes” option in the settings page.

Usage example: [FSM_featured_image size=thumb]

For developers

The plugin comes with two public functions that allow you to get or output the featured image caption of the current post anywhere in your template.

Once the plugin is activated, use <?php get_FSM_featured_image_caption()?> to return a string containing the text that you can assign to a variable or <?php the_FSM_featured_image_caption()?> where you like the caption be displayed.

Both functions accept parameters passed inside an array with the following keys:

  • tag: The tag (without brackets) you want to use as a container. By default is div. If set to false, it will remove it and will return the caption text.
  • class: The name of the class/classes you want to use for the container. Use spaces to separate them. Empty by default.
  • style: The CSS styles to be used in the container tag. Empty by default.
  • force_visibility: When set to true, it ignores the hide caption option defined by the post editor. Useful for displaying your caption in a different place, but showing the featured image. Default: false.
  • allow_html: like in the settings page, if set to true, allows the browser to parse the HTML code inside the caption text, else shows it as plain text. Default: false.
  • allow_shortcodes: again the same behaviour than in the settings page. Default: false.
  • ignore_original_caption: stops using captions defined in the media library as a substitution when the caption field is empty. Default: false.

Usage example: php
the_FSM_featured_image_caption( array('tag' => 'p', 'class' => 'class1 class2', 'style' => 'color: red;', 'allow_html'=> true, 'allow_shortcodes'=>true );

Translations

The plugin comes up with three complete translations:

  • English (en)
  • Spanish (es_ES)
  • Catalan (ca)

You can contribute to translating it into more languages at https://translate.wordpress.org/projects/wp-plugins/fsm-custom-featured-image-caption/

Coming soon

  • More options for selecting the text to be used as the caption, allowing to choose amongst image Title / Caption / Alt Text / Description and custom text.
  • Options to fine-tune the shortcode.
  • Have more ideas? We are open to hearing!

Pricing

Starting from $0 per month.

Check Out the Social Votes Widget

By Common Ninja

Social VotesTry For Free!

App Info

Rating

Reviewers

20 reviews

Tags

caption
copyright
credits
featured image
images

Developed By

fesomia

Quick & Easy

Find the Best Wordpress plugins for you

Common Ninja has a large selection of powerful Wordpress plugins that are easy to use, fully customizable, mobile-friendly and rich with features — so be sure to check them out!

Testimonial

Testimonial plugins for Wordpress

Contact Form

Contact Form plugins for Wordpress

Maps

Maps plugins for Wordpress

Translation

Translation plugins for Wordpress

Chat

Chat plugins for Wordpress

Slider

Slider plugins for Wordpress

Reviews

Reviews plugins for Wordpress

Contact

Contact plugins for Wordpress

Galleries

Galleries plugins for Wordpress

SEO

SEO plugins for Wordpress

Forms

Forms plugins for Wordpress

Comments

Comments plugins for Wordpress

Backup

Backup plugins for Wordpress

Privacy

Privacy plugins for Wordpress

Optimize

Optimize plugins for Wordpress

Tabs

Tabs plugins for Wordpress

Social Sharing

Social Sharing plugins for Wordpress

Events Calendar

Events Calendar plugins for Wordpress

Comments

Comments plugins for Wordpress

Social Feeds

Social Feeds plugins for Wordpress

Social Sharing

Social Sharing plugins for Wordpress

Portfolio

Portfolio plugins for Wordpress

Video Player

Video Player plugins for Wordpress

popup

popup plugins for Wordpress

SiteMap

SiteMap plugins for Wordpress

Payment

Payment plugins for Wordpress

Coming Soon

Coming Soon plugins for Wordpress

Inventory

Inventory plugins for Wordpress

Testimonials

Testimonials plugins for Wordpress

Portfolio

Portfolio plugins for Wordpress

Membership

Membership plugins for Wordpress

Forms

Forms plugins for Wordpress

Analytics

Analytics plugins for Wordpress

Events Calendar

Events Calendar plugins for Wordpress

Sliders

Sliders plugins for Wordpress

Analytics

Analytics plugins for Wordpress

Reviews

Reviews plugins for Wordpress

Security

Security plugins for Wordpress

Ads

Ads plugins for Wordpress

Music Player

Music Player plugins for Wordpress

Countdown

Countdown plugins for Wordpress

Email Marketing

Email Marketing plugins for Wordpress

Membership

Membership plugins for Wordpress

Ecommerce

Ecommerce plugins for Wordpress

Customer Support

Customer Support plugins for Wordpress

Video Player

Video Player plugins for Wordpress

Tabs

Tabs plugins for Wordpress

Social Feeds

Social Feeds plugins for Wordpress

Common Ninja Apps

Some of the best Common Ninja plugins for Wordpress

Browse our extensive collection of compatible plugins, and easily embed them on any website, blog, online store, e-commerce platform, or site builder.

Social Votes for Wordpress logo

Social Votes

Encourage interaction with social votes that let visitors like, upvote, and rank content, boosting engagement and guiding better decisions.

Donation Button for Wordpress logo

Donation Button

Add a donation button that lets users contribute easily using PayPal or Stripe, supporting causes directly from your site.

GDPR Cookie Notice for Wordpress logo

GDPR Cookie Notice

Show a GDPR-ready cookie notice that clearly explains how cookies are used, helping you stay compliant while creating a more transparent experience for your visitors.

Google Maps for Wordpress logo

Google Maps

Show business locations clearly with a Google Maps widget that displays multiple points, detailed info, and customizable styles to help visitors find you easily.

Event Listings for Wordpress logo

Event Listings

Create event listings with an events board widget that displays upcoming activities clearly, helps visitors discover events, and supports easy management.

Social Share Buttons for Wordpress logo

Social Share Buttons

Add social share buttons so visitors share content to major networks, boost engagement, and drive more referral traffic.

G2 Reviews for Wordpress logo

G2 Reviews

Show G2 reviews to build trust, strengthen credibility, and help visitors make confident SaaS buying decisions that support higher sales.

Multi-Row Image Slider for Wordpress logo

Multi-Row Image Slider

Showcase visuals with a multi row image slider that displays images in layered rows, improves design, and helps visitors explore content more easily.

Process for Wordpress logo

Process

Use a process widget to present tasks in a clear visual sequence, showing each step with images and text to improve understanding and user engagement.

Image Gallery for Wordpress logo

Image Gallery

Showcase photos with an image gallery that displays pictures and captions in grids, improves design, and boosts visitor engagement.

Stories for Wordpress logo

Stories

Add interactive stories to your site to showcase content in a visual, mobile friendly format that boosts engagement and guides visitors toward action.

Device Mockup for Wordpress logo

Device Mockup

Show products, apps, or designs inside a clean device mockup that improves visualization, builds credibility, and helps visitors make confident decisions.

Discover Apps By Platform

Discover the best apps for your website

WordPress
Wix
Shopify
Weebly
Webflow
Joomla
PrestaShop
Shift4Shop
WebsiteX5
MODX
Opencart
NopCommerce

Common Ninja Search Engine

The Common Ninja Search Engine platform helps website builders find the best site widgets, apps, plugins, tools, add-ons, and extensions! Compatible with all major website building platforms - big or small - and updated regularly, our Search Engine tool provides you with the business tools your site needs!

Multiple platforms