Home Forums Support Posts-Page Header

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #201283
    David

    Hi Tom – I’m having a heck of a time figuring out what’s going on with my Posts Page (http://2011disaster.jcie.org/recoveryjournal/). It is showing content header, but I had deleted it from the Page Header > Content Settings on its Page Admin.

    There are two other items I can’t quite figure out:
    1) Reducing space between header content and posts/ sidebar (tried all types of ccs to override)
    2) Add breadcrumbs to this page.

    Thanks!

    #201287
    David

    Update: I was able to close the gap between the header content and the posts archive, but I still am not sure where the page header content is coming from. I had deleted it a while ago.

    #201289
    David

    Scratch that. It was a cache left over from using Chrome’s Developer tools. Gap between header content and posts is still there.

    #201319
    Tom
    Lead Developer
    Lead Developer

    You have the full screen option set in the Content settings in Page Header.

    If you disable full screen it will go away 🙂

    #201372
    David

    Awesome and thank you. When I updated GeneratePress Page Header moved to the Customizer and that threw me off as well. Gap issue is fixed and I also see where I can edit my content again.

    #201378
    David

    Last item – how would I go about showing breadcrumbs on the Posts Page and also on the tag archives such as: http://2011disaster.jcie.org/fund-updatetag/aar-japan/. Breadcrumbs through Yoast is working elsewhere correctly. Thanks in advance!

    #201440
    Tom
    Lead Developer
    Lead Developer

    What code are you currently using the display the breadcrumbs?

    #201581
    David

    Hi Tom – I have the following GP Hook After Header:

    <?php if ( function_exists('yoast_breadcrumb') ) { ?>
        <?php if ( is_single() ) : ?>
    	<div class="grid-container grid-parent">
    		<div class="page-header">
    			<?php yoast_breadcrumb('<p id="breadcrumbs">','</p>'); ?>
    	
    		</div>
    	</div>
        <?php endif; ?>
    <?php } ?>
    • This reply was modified 5 years, 1 month ago by Tom.
    #201587
    Tom
    Lead Developer
    Lead Developer

    is_single() makes it so it will only show on single posts.

    So you want this instead:

    <?php if ( function_exists('yoast_breadcrumb') ) { ?>
        <div class="grid-container grid-parent gp-breadcrumbs">
            <div class="page-header">
                <?php yoast_breadcrumb('<p id="breadcrumbs">','</p>'); ?>
            </div>
        </div>
    <?php } ?>
    • This reply was modified 5 years, 1 month ago by Tom.
    #201588
    David

    OK so that works, but then the breadcrumbs are now showing up on pages that I don’t want them too such as the home page (Page ID = 2). I was trying to use this CSS to hide them:

    .page-id-2 .site-breadcrumbs {
          display: none;
    }
    #201590
    David

    Hi Tom – I updated from “.site-breadcrumbs” to “#breadcrumbs”. Back to working, I just need to get rid of the spacing now on the pages where breadcrumbs are being hidden. For instance on the home page the main image should be flush up against the menu: http://2011disaster.jcie.org/

    Thank you for the help (and quick replies at that)!

    #201592
    Tom
    Lead Developer
    Lead Developer

    I adjusted the PHP above.

    Now use this CSS to hide them:

    .gp-breadcrumbs {
        display: none;
    }
    #201594
    David

    Brilliant. Thank you. That’s a much easier solution than hard coding the css for each page where breadcrumbs shouldn’t be.

    #201596
    Tom
    Lead Developer
    Lead Developer

    You’ll still need to do that, the CSS above will remove it on all pages.

    However, you can use our Simple CSS plugin which adds a CSS metabox on each page, so you can just pop that code in there instead of finding IDs and adding a bunch of them: https://wordpress.org/plugins/simple-css/

Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.