fusi0n
15Jan/12

#Newnewtwitter Keyboard Shortcuts

Twitter's new design, the second one since the mass adoption of the platform, lovingly called #newnewtwitter was just enabled on my account. You can get a nicer output than what's below by pressing '?' in #newnewtwitter. They're pretty useful keyboard shortcuts - if you, like me, find yourself using the Web version more often than anything else.

Actions Navigation Timelines
F Favorite ? This menu G H Home
R Reply J Next Tweet G C Connect
T Retweet K Previous Tweet G A Activity
M Direct message Space Page down G R Mentions
N New Tweet / Search G D Discover
Enter Open Tweet details . Load new Tweets G P Profile
L Close all open Tweets G F Favorites G M Messages
G U Go to user...
8Jun/11

Twitter Direct Messages Bulk Deleter

If you're a Twitter user and a organisation freak, you're certainly aware that Twitter doesn't give you the ability to bulk-delete direct messages. Back in the days, Damon Cortesi had built a nifty bookmarklet that allowed you to stick it to the man. Problem is, that bookmarklet is now deprecated, due to Twitter's change of layout - most of the stuff just doesn't work the way it used to, so the infamous DM Whacker was laid to rest.

Until I got really fucking tired of all the direct messages. Here's a reboot of Damon Cortesi's DM Whacker: DMDelete-v2.0. It's fast, uses Twitter-specific resources (such as their jQuery and dialogs), and is merciless. Give it a try, all you have to do is drag the link blow to your bookmark toolbar (or wherever you want really), go to your Twitter inbox and click it!

This is beta software! Feel free to relay any feedback you might have after using - it's rather challenging to thoroughly test this piece of code on my own, so there may be random hiccups.

DMDeleter-v2.0

Browse the source

11Nov/10

10 of the Best WordPress Plugins

WordPress is an extremely powerful and popular blogging platform. There are over 27 million WordPress publishers as of September 2010: 13.9 million blogs hosted on WordPress.com plus 13.8 million active installations of the WordPress.org software (source). If that's not enough, there are 17,428 registered plugins to extend its functionality and 4,406 registered themes to modify its look. With all that, it can get complicated to choose the best plugins to achieve what you want. Here's a list of my personal favourites.

23Apr/10

Consolidating Facebook’s Takeover of the Net: Bookmarklet to “Like” Anything!

I was wondering, last night, if I'd really have to wait for everyone to implement the new Facebook Social Plugins, more specifically, the new embeddable "Like Button". I think it's a pretty cool alternative to replace everyone's "Share on Facebook" annoying popup link. That being said, I decided I'd throw a little JavaScript together, actually inspired by Damon Cortesi's DM Deleter for Twitter, I put together a bookmarklet to insert a "Like" button virtually anywhere (and by that, I mean on any site/page you visit).

First, for those who want the result before the explanation, drag this link to your browser's bookmark toolbar: Like This

Alright, now for the smart people, here's a breakdown of what this puppy does:


javascript:(function(){
var h=document.getElementsByTagName('head')[0];
var m1=document.createElement('meta');
m1.setAttribute('property','og:title');
m1.content=document.title;
h.appendChild(m1);

var m2=document.createElement('meta');
m2.setAttribute('property','og:site_name');
m2.content=window.location.hostname;
h.appendChild(m2);

var m3=document.createElement('meta');
m3.setAttribute('property','og:url');
m3.content=window.location;
h.appendChild(m3);

var s=document.createElement('iframe');
s.scrolling='no';
s.frameborder='0';
s.allowTransparency='true';
s.style.border='none';
s.style.overflow='hidden';
s.style.position='absolute';
s.style.zIndex='100';
s.src='http://www.facebook.com/plugins/like.php?href='+encodeURIComponent(window.location)+'&layout=standard&show_faces=true&width=450&action=like&colorscheme=light';
var a=document.body.firstChild;
document.body.insertBefore(s,a);
})();void(0);

What that is gonna do is relatively simple and most of you will be able to guess it just by looking at the code above. It creates three META tags, one for og:title, one for og:site_name, and one for og:url which are all required by Facebook to display the data that you actually like.
Once that's done, it creates an iframe, exactly the same as just getting the Like Button code from Facebook and puts it as the first element of the body tag, making it the first thing you see on the page, technically.

This is mostly a little toy, but feel free to use it if you'd like! I'm not too sure why, but when I tried this at home, it would pop up a Facebook login window instead of just "Liking" whatever I was supposed to be Liking... this morning, it doesn't. So let me know what you experience if you try it out.

Edit: ReadWriteWeb is also saying they've got a "Safe" bookmarklet. But theirs don't add meta tags :)

13Feb/09

Make your WordPress plugins use a different version of a bundled JavaScript library

I've recently coded my first WordPress plugin, for the fun of it. I've been using WordPress for some time, and I know PHP quite well, so I figured it'd be fun. WordPress has a weird/interesting way of being extendable. I won't go into too much technical details about that, but suffices to say that it's easy yet complicated to perform tasks you want to. Yeah, that weird.

All that being said, I upgraded my WordPress from 2.7 to 2.7.1 in the middle of coding some new features for the latest release of WP-prettyphoto, 1.1. That made me realize that updating WordPress' core also updates the installed JavaScript modules, namely jQuery (among many others). When I first coded WP-prettyphoto, when things weren't working I just replaced the jQuery I had with the latest official stable release and things worked fine. I didn't give it much thought. So when I updated WordPress, all hell broke loose and WP-prettyphoto was metaphorically crying in agony because jQuery wasn't man enough for it. I then tried performing the same manual updating procedure, and without really surprising anyone -- I was alone anyway -- WP-prettyphoto was back prettyfying my stuff like a starving fat kid eats a cheesecake.