jetpack by wordpress.com – location of share buttons
-
I am currently using the jetpack by wordpress.com to add my sharing buttons. I would like to move the location of the sharing buttons to right after my post content instead of after the related posts section (i.e. move the location up). I would like to follow the instructions below but am having a hard time figuring out what file exactly to add the ‘<?php echo sharing_display(); ?>’ to? I do not know what php file to add that code to or where to find the body or content of my posts so i can make sure the share buttons are located right after each post? Thanks for the help!
Start by adding the following code to your theme’s functions.php file:
function jptweak_remove_share() {
remove_filter( ‘the_content’, ‘sharing_display’,19 );
remove_filter( ‘the_excerpt’, ‘sharing_display’,19 );
}
add_action( ‘loop_end’, ‘jptweak_remove_share’ );Then, locate the exact place where you’d like your sharing buttons to appear in your template files, and add the following code:
<?php echo sharing_display(); ?>
- The topic ‘jetpack by wordpress.com – location of share buttons’ is closed to new replies.