There should be no link if you don’t add a URL in the field for the featured image caption. I will check the code for this behavior and see if it’s got a bug though.
There is still a link on the caption text after removing the URL in the Source field as you can see from the HTML code below.
<div class="featured-image">
<a href="http://kirsten.osa-family.me/my-travels" rel="bookmark">
<img width="1000" height="576" src="http://kirsten.osa-family.me/wp-content/uploads/travel/birding/Yellowstone/090-2017-08-30-07-44-47-1000x576.jpg" class="attachment-nisarg-full-width size-nisarg-full-width wp-post-image" alt="" />
<div class="ccfic"><span class="ccfic-text">Castle Geyser in Yellowstone national Park</span></div>
</a>
</div>
Can you copy and paste the Debug output found on the plugin settings page? Admin > Settings > Featured Image Caption
Version Information
Plugin: 0.8.9
WordPress: 5.1.1
PHP: 7.2.16
Theme
Name: Nisarg
Version: 1.2.8.2
-
This reply was modified 6 years, 1 month ago by
kirstenosa.
No change after updating to 0.8.9. The problem with the link remains the same.
-
This reply was modified 6 years, 1 month ago by
kirstenosa.
I have seen similar behavior with certain themes, such as the Twenty Nineteen theme that comes with WordPress. I think it has to do with how I target the HTML in the page, so I will need to see if there is a better way to do this that alleviates this issue.
In the mean time, you can disable automatically inserting the caption, and edit the theme to place it exactly where you want. Not an ideal solution, I know, and I do plan to figure out how to get around this problem.
Hi Christiaan,
I am having the same bug issue.
Debug:
Version Information
Plugin: 0.8.9
WordPress: 5.2.3
PHP: 7.1.30
Theme
Name: Avada Child
Version: 1.0.0
Screenshots:
Screenshot 1
Screenshot 1a
Screenshot 2
Screenshot 2a
You said, “In the mean time, you can disable automatically inserting the caption, and edit the theme to place it exactly where you want.”
I can duplicate and edit a core theme file to the child theme, but I am a bit confused.
Is it the wp-content/theme/Avada/single.php?
Is there a specific line of code?
Thank you.
-
This reply was modified 5 years, 8 months ago by
alondonb.
-
This reply was modified 5 years, 8 months ago by
alondonb.
For anyone else struggling with this, I found how to correct it based on the directions Christaan gave above. Hopefully this bug will be fixed.
In the meantime:
Use a code editor with FTP or SSH like Filezilla, etc. This way if something breaks you will still have access to the code to undo it.
Go to your wp-content/theme folder. Download the single.php file or whichever file the theme developer says is the one for individual blog posts.
In the file find the line of code that says something like “featured image” – mine happens to be ?php avada_singular_featured_image(); ?>
Under that line of code, place this:
<? cc_featured_image_caption(); // This hardcodes the Featured Image Caption into this theme ?>
Best practices here is to make a child theme of your theme, so after updates you won’t lose this workaround. Save/upload the changed file as a file in your child theme. This way when the theme loads up it will load the original first, then this new one with the changes last. So yes, you will have two single.php files total. One in the regular theme and one in the child theme.
This works, but you will notice there is a space between the featured image and the caption. The caption is also to the left, and I wanted mine to the right.
Go to you CSS file in the child theme or use a plugin.
Add this:
.ccfic {
text-align: right;
margin-top: -30px;
}
I had to use a negative margin to bring it up. There is some debate on negative margins but it works for this instance.
Voila!