[Resolved] How to remove "featured images" from displaying on posts

Home Forums Support How to remove "featured images" from displaying on posts

Viewing 6 posts - 16 through 21 (of 21 total)
  • Author
    Posts
  • #75572
    Tom
    Lead Developer
    Lead Developer

    Ha, option a is definitely a no-go then.

    Interesting issue – I’ll look into adding a class to the page header container that specifies whether it’s a featured image or a regular page header.

    Question: If you have so many recipes, how have you added the header using the Page Header add-on? And why not just add your header in the “Header Content” section of the Customizer?

    #75634
    Richard Prisco

    >>>Interesting issue – I’ll look into adding a class to the page header container that specifies whether it’s a featured image or a regular page header.
    ThanX

    >>>Question: If you have so many recipes, how have you added the header using the Page Header add-on? And why not just add your header in the “Header Content” section of the Customizer?

    In the page header i put just put the logo’s for the copycat recipes; as a result, there are only about 200 copycat recipes.

    #76321
    Tom
    Lead Developer
    Lead Developer

    Can you link me to one of the recipes where this issue is occurring? It will help me come up with a solution 🙂

    #76611
    Richard Prisco

    Hi Tom,

    I have this on my local test/file server which is not on the inet. I was upgrading my linux box (main web server) and I had my fifth heart attack(3 operations for that one) and then on top of all that, my mother passed away. My mother was 14 when she had me; so she was very close to me and to my age, so I have been in mourning. I am now trying to keep busy (as my wife says this is good) and keep calm (the recipes and cooking). But, I need to wait for my brother to put the server on the rack for me. Can’t lift and with me everything is done real slow, so slow i feel like a snail, sometimes I think road kills moves faster. The web box when it was running was private (just family & friends), I could have given you guest access, but until that’s up, there is no access. So I will have to try to explain via picture.

    PAGE LAYOUT NOW
    ———————————————————
    Main Header
    Main menu
    ———————————————————
    <DIV class=”featuredimg”>Featured Img 1 / Your Page Header Img (from post editor)</DIV>
    here if you turn off featuredimg, both go off
    ———————————————————
    Recipe Template with recipe img. —————
    | |
    | img 1 |
    | |
    —————

    ———————————————————–
    Footer
    ———————————————————–

    ========================================================================================

    PROPOSED PAGE LAYOUT
    ———————————————————
    Main Header
    Main menu
    ———————————————————
    above: <DIV class=”pgheaderimg1″>Your page header img</DIV>
    <DIV class=”featuredimg”>Featured Img 1 / NO Page Header Img (from post editor)</DIV>
    below: <DIV class=”pgheaderimg2″>Your page header img</DIV>

    or choice
    In pg header settings
    Extended Page Header Setting
    [x] above featuredimg <DIV class=”pgheaderimg1″>
    [ ] below featuredimg <DIV class=”pgheaderimg2″>
    ———————————————————
    here you can …
    turn off featured img css display:none
    and still have your pg header img appear either above or below featured imgs

    and now you have another enhancement to your already wonderful prog.

    I hope I made myself clearer?

    Thanx again for your time and wonderful prog.

    Best regards,

    Richard

    #150430
    Ramon

    hi Tom, does the option is already in GP yet? display:none will load the image, and not good for speed, i hope the option will also for home, archive, and so on.. not just for is_single

    #150491
    Tom
    Lead Developer
    Lead Developer

    @rtprisco – Wow, don’t know how I missed your post! Are you still needing help with this? Sorry about the huge wait!


    @Ramon
    , this PHP should remove the code completely:

    add_action( 'wp', 'generate_remove_single_featured_image' );
    function generate_remove_single_featured_image()
    {
        if ( is_single() ) :
            remove_action('generate_before_content','generate_featured_page_header_inside_single', 10);
        endif;
    }

    Adding PHP: https://generatepress.com/knowledgebase/adding-php-functions/

Viewing 6 posts - 16 through 21 (of 21 total)
  • You must be logged in to reply to this topic.