Home / loop / Share on Facebook
  • How to Share on Facebook

    share-on-facebook

    Place this PHP code within the loop of your wordpress theme index.php and visitors can click this link to share your post on Facebook.

    ( click code to copy )

    wordpress snippet : PHP

    <>
    <a href="http://www.facebook.com/sharer.php?u=<?php the_permalink();?>&t=<?php the_title(); ?>" title="Share this post on Facebook" target="blank" rel="nofollow">Share this post on Facebook</a>
    

    ( WordPress codex functions, hooks, in this snippet. )

    the_title, the_permalink,
  • Did not know Facebook share was this simple, huh learn something new everyday.