Share URLs for Facebook and Twitter
Posted on the 04.04.2011 at 20:32 by Rasmus Burkal
I just had a question at work today, around how to post stuff to Facebook and Twitter from custom icons, here is a simple solution.
For Facebook:
http://www.facebook.com/sharer.php?u=http%3A%2F%2Fwww.rabu.dk
It takes the argument “u” for the URL you want to share.
For Twitter:
http://twitter.com/share?url=http%3A%2F%2Fwww.rabu.dk
It takes the argument “url” for the URL you want to share.
Remember to URL-encode the URL parameter!
Both URLs should be opened in a pop-up or a lightbox.



Comments
Commented on the 07.01.2012 at 21:41
[...] just had a question by email recently, from a guy who have read my blog post, on how to share URLs on Facebook and Twitter. He was asking if I knew about a way, on how to do a similar URL share for Google+. And yes, I do [...]
Leave a reply
To leave a reply, you must be logged in.