[Resolved] Remove Duplicate Category Link On Category, Archive, Author, and Single Posts

Home Forums Support [Resolved] Remove Duplicate Category Link On Category, Archive, Author, and Single Posts

Home Forums Support Remove Duplicate Category Link On Category, Archive, Author, and Single Posts

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1613878
    Michelle

    I am using a category link in my meta (CSS).

    Problem is, by default there is a category link beneath excerpts on category, archive, and author pages; and also in the post navigation of my single post pages. I want to remove the category link beneath the excerpts and at the bottom on my single post pages.

    Unchecking “Show categories” removes the category link beneath the excepts, BUT ALSO IN THE META.

    How can I get rid of the extra category links?

    #1613896
    Elvin
    Staff
    Customer Support

    Hi,

    You can try adding this PHP snippet:

    add_filter( 'generate_header_entry_meta_items', function() {
        return array(
            'author',
            'date',
            'categories',
        );
    } );
    
    add_filter( 'generate_footer_entry_meta_items', function( $items ) {
        return array(
            'post-navigation',
        );
    } );

    Here’s how to add PHP snippets to your site:
    https://docs.generatepress.com/article/adding-php/

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

    #1616250
    Michelle

    Thank you.

    #1616459
    Elvin
    Staff
    Customer Support

    Thank you.

    No problem. Glad to be of any help. 😀

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

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