Skip to content

Instantly share code, notes, and snippets.

@erezLieberman
Created May 6, 2015 11:57
Show Gist options
  • Save erezLieberman/58297c24c16fd058d278 to your computer and use it in GitHub Desktop.
Save erezLieberman/58297c24c16fd058d278 to your computer and use it in GitHub Desktop.
social urls in wp
<a class="share_twitter" href="https://twitter.com/home?status=<?php the_title();echo " - ". $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"] ?> " target="_blank">
TWITTER
</a>
<a class="share_twitter" href="http://www.facebook.com/sharer/sharer.php?u=<?php echo $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"] ?>&t=<?php the_title(); ?>" target="_blank">
FACEBOOK
</a>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment