Closed Shapeshifter3 closed 10 years ago
Is there a theme, or themes, in particular that you're referring to? Most well-built themes will output components like a featured image using a hook, which means that you can easily modify/remove those components with a proper call to remove_action
or remove_filter
. Sometimes it takes some sleuthing to find the right hook, but I'll usually just run a search across all theme files for a bit of the html in a component (e.g. class="featured-image"
or even just featured-image
) to see where it's being spit out.
I found this issue in both Twenty Thirteen, and Sorbet.
Gotcha, thanks. Well, digging into Twenty Thirteen, it looks like I was wrong - no hook. Looking in content.php, here's the code for the thumbnail:
<div class="entry-thumbnail">
<?php the_post_thumbnail(); ?>
</div>
So it looks like your options are a bit more limited.
.entry-thumbnail {
display: none;
}
Sorry to not be more helpful. Mark or someone else might come along with a much better solution, but this is how I'd do it. Good luck!
@MickeyKay's suggestions are good, in the case that the theme has hardcoded this function into one of their templates. Do note that hiding it with CSS won't stop it from loading, so it's a bit of a bummer from an efficiency standpoint. Just creating a child them is a good idea anyway.
Mr. Jaquith,
Several (or more) of Automattic's WordPress Themes place the Featured Image of Blog Posts (formatted as "Standard") at the top of the post itself when the image is clicked as a link to the post.
Is there any Code Snippet(s) that I can use to insert into any theme that displays this problem?