Skip to content

Instantly share code, notes, and snippets.

@mikeknoop
Created March 6, 2013 04:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mikeknoop/5096819 to your computer and use it in GitHub Desktop.
Save mikeknoop/5096819 to your computer and use it in GitHub Desktop.
<?php
$code = "XXXX";
$u = urlencode(get_permalink());
$t = urlencode(get_post()->post_title);
$next = "http://news.ycombinator.com/submitlink?u=".$u."&t=".$t;
$next = urlencode($next);
$href = "http://zapier.webscript.io/click?next=" . $next . "&zid=" . $code;
?>
<a class="hn" href="<?php echo $href; ?>">Upvote and Comment on Hacker News</a>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment