Remove "Featured Image" from showing up in gallery as well.

Viewing 8 posts - 1 through 8 (of 8 total)
  • #3823
    Elissa
    Participant

    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!

    #3937
    khx
    Participant

    Upload 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.

    #3942
    Elissa
    Participant

    My pictures are already uploaded into the media library (through the gallery post)
    and chosen as featured image. They still show up on both.

    #3982
    sarah
    Participant

    I 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

    #5348

    Note: 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 & Media

    #5377
    Daniel Tara
    Keymaster

    Open content-gallery.php and remove the reference to the_post_thumbnail();

    #11937
    Vincent_Karma
    Participant

    Removing 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.

    #11969
    Vincent_Karma
    Participant

    If 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.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.