[Resolved] Full Width Heading in single post

Home Forums Support [Resolved] Full Width Heading in single post

Home Forums Support Full Width Heading in single post

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #1525750
    Rohan Verma

    I want to have full width heading in single post that will be over both content and sidebar. Under that date and author. I tried with hero elements but updated date is not showing. I want something like this: https://prnt.sc/vgxech

    Thanks and regards

    #1525882
    Elvin
    Staff
    Customer Support

    Hi,

    Can you link us to the site you’re working on?

    You can provide the details on the Private Information text field. Thank you. 🙂

    A wise man once said:
    "Have you cleared your cache?"

    #1525921
    Rohan Verma

    Updated

    #1525954
    Elvin
    Staff
    Customer Support

    The Header Element (.page-hero) is the way to go.

    You just need to change the markup to display the date and the author. To do that, refer to this documentation:
    https://docs.generatepress.com/article/page-hero-examples/#example-2

    As you can see on the example, it displays the date and author. (and author image).

    This is its markup:

    <h1>{{post_title}}</h1>
    [page_hero_gravatar] {{post_author}} {{post_date}}

    Just remove the [page_hero_gravatar] if you don’t need it.

    A wise man once said:
    "Have you cleared your cache?"

    #1526150
    Rohan Verma

    Its showing the regular date not the updated date How to show the modified date

    #1526156
    Elvin
    Staff
    Customer Support

    Try Tom’s answer here:

    https://generatepress.com/forums/topic/correct-way-to-show-only-modified-date-on-page-hero/#post-1344687

    A wise man once said:
    "Have you cleared your cache?"

    #1526261
    Rohan Verma

    Everything is working. Just two more thing.
    1) How to put the breadcrumb above the title on page hero
    2) how to change the size of author name and date in page hero. The site link is given in private

    #1526429
    David
    Staff
    Customer Support

    Hi there,

    1. The plugin you’re using to create the breadcrumb – you can add its shortcode inside the Header Element before the title.

    2. Edit the header element and wrap the post meta like so:

    <div class="hero-meta">by {{post_author}} | {{post_date}}</div>

    Then add this CSS:

    .hero-meta {
       font-size: 14px;
    }
    #1526598
    Rohan Verma

    We have already added a hook with the Yoast breadcrumb code before generate_before_entry-title

    <?php
    if ( function_exists('yoast_breadcrumb') ) {
      yoast_breadcrumb( '<p id="breadcrumbs">','</p>' );
    }

    Screenshot: https://prnt.sc/vhepha

    Please guide us to move the breadcrumb to move above page hero

    #1526933
    David
    Staff
    Customer Support

    As i said the simplest method is to use a Header Element.
    Yoast provides a Short Code for the Breadcrumbs which you can find here:

    https://yoast.com/help/implement-wordpress-seo-breadcrumbs/#pageshortcode

    Add that to the Header Element. And remove the one you have added to the Hook Element.

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