-
ElissaParticipant
Can I remove the featured image from showing up in the gallery? I only want the featured image to show up in the main page slider, and have different images in the gallery.
Any help would be much appreciated. Thanks!
khxParticipantUpload the picture you want to use as the featured image by going to Media > Libraray > Add New then click to add the featured image and select the photo from the media library. That will make the photo appear on your homepage but not in your gallery.
ElissaParticipantMy pictures are already uploaded into the media library (through the gallery post)
and chosen as featured image. They still show up on both.sarahParticipantI want to remove the pics from my posts too (not all, but some) and I can’t. An answer to this would be useful please Daniel
Earthman Web & MediaParticipantNote: The following PHP code should be added to your theme’s .php template file(s) rather than in the WYSIWYG editor:
<?php
// get the post's thumbnail ID so this code can be used inside OR outside the 'loop'
$the_thumbnail_id = get_post_thumbnail_id($post->ID);
// display the gallery (exclugin the thumbnail)
$gallery_shortcode = '[gallery exclude="'.$the_thumbnail_id.'" id="' . intval( $post->ID ) . '" link = "file" size="tiny" columns="6"]';
// *Note usage of additional options for Gallery Shortcode, as per: http://codex.wordpress.org/Gallery_Shortcode
echo apply_filters( 'the_content', $gallery_shortcode );?>
Hope this helps you out!
Terran Orletsky
Earthman Web & MediaDaniel TaraKeymasterOpen content-gallery.php and remove the reference to
the_post_thumbnail();
Vincent_KarmaParticipantRemoving that line removes the thumbnail but does not change the fact that the image posts twice. I’m still trying to figure this out too.
Vincent_KarmaParticipantIf you upgrade to 3.5 and edit the gallery, you will have the option to delete from the images from the gallery without removing the desired image from the “Featured Image” on the post. This fixed the issue for me.
Tagged: Featured Image, gallery, wordpress
You must be logged in to reply to this topic.