• Hi,

    I’m having issues with the sharing buttons on the custom post type archive page. Rather than sharing the archive the last post is being shared instead.

    e.g.

    What is being shared:
    https://mysite.com/team/newest-member/

    Rather than:
    https://mysite.com/team/

    I am using the following to remove the default sharing buttons from the post content:

    remove_filter( 'the_content', 'sharing_display',19 );
    remove_filter( 'the_excerpt', 'sharing_display',19 );
    if ( class_exists( 'Jetpack_Likes' ) ) {
        remove_filter( 'the_content', array( Jetpack_Likes::init(), 'post_likes' ), 30, 1 );
    }

    and this following to add it to a template part:

    /* check sharing function is available */
    if ( function_exists( 'sharing_display' ) ) {
    
        /* output sharing buttons */
        sharing_display( '', true );
    
    }

    Here’s the site – https://senecapartners.co.uk/deal-credentials/

    Hope someone can help me with this.

    Thanks,
    Matt

    https://www.ads-software.com/plugins/jetpack-sharing/

  • The topic ‘Custom Post Type Archive Page Sharing’ is closed to new replies.