I know you’ve written about how to create an “add me” button for MySpace, but, um, I’m not on MySpace, I’m on Facebook. is there some way to build or hack together an “add me” button for Facebook to add to my site instead? Thanks.
That’s an interesting question, and generally my answer would be “no” because Facebook has put a lot of effort into creating its own universe, generally one that’s not easily reached from the rest of the Internet at large.
However, a colleague (thanks Trent Urbanski) gave me a little tip on how to reverse engineer just this sort of thing so let me share it with you so you too can create a nice “let’s connect on Facebook” button for your blog or Web site…
The first thing you need to do is figure out your numeric account ID on Facebook.
The fastest way I know to get this information is to click on “Profile” on the top menu of your Facebook home page:
Now scroll down a bit and you’ll see your “Friends” box:
Turns out that the link that shows you how many friends you have includes your Facebook account ID number, as you can see here:
You can simply copy that link with a Cmd-Click (or Right-Click) and paste it into an edit buffer to extract the numeric value. Mine account ID is 500501552 as you can see.
Now here’s the hacking part: the link you want to create looks like this:
For me, for example, it’d be:
To make it into a button, simply wrap it in some rudimentary HTML:
That code looks like this in action:
Tweak and modify to your hearts content, and enjoy!
I’d also like to let you know that I have quite a bit of Facebook help here on the site and that I also have an Ask Dave Taylor Facebook Fan Page that I invite you to join.