bookmarklet

Save yourself from the Twitpocalypse with this handy bookmarklet

The Twitpocalypse is upon us, and a whole lot of things have broken...

In some cases it's recoverable though. If you click a link from your favorite Twitter-related service and come across a URL like this, you can fix it! Just use this handy dandy little bookmarklet and you'll be back on the right Tweet in no time.

UNpocalypse!

Use this like you normally use a bookmarklet. Drag it to your bookmark bar, or right click and "save as bookmark".

The standard bookmarklet disclaimers apply: This works in Firefox and Safari, but might not work in all browsers. It's a quick and dirty bookmarklet, so if you use it somewhere it doesn't belong it will do unexpected things with your browser. Don't try using it on non-Twitpocalypsed tweets, as it will try to grab some random tweet from the far distant future.

a better TinyURL bookmarklet!

TinyURL is amazing. They shortify any URL, so you can change from something long and heinous—think Google Maps addresses—to something far more palatable (ala http://tinyurl.com/2h5z5m). The end result is short, pithy, and emailable. They magically redirect it to the real URL for you, and the Internets are a better place for all of us. Check out their example:

that's one TinyURL...

As if this wasn't cool enough, TinyURL recently added the ability to tack on a custom alias. Now you can (optionally) choose a word or phrase to include in the hash portion of the tinyfied address, making it memorable as well as emailable. So now something like http://tinyurl.com/justin-hileman is possible.

Unfortunately the bookmarklet they provide only generates the old style TinyURLs with numbers and junk at the end. I use it all the time, so I decided it's time for an upgrade. I created a bookmarklet that lets you select a chunk of text to be used as the alias. it automatically converts the selected text so it's url friendly and everything!

Just drag this bookmark to your bookmark bar (or right click/save link as):

TinyURL!

To use it, browse to a page on the internet, select a word or two, and click the bookmarklet. MagicURL!

Note: this should work in any real browser. Read: you shouldn't expect anything in IE < 7. Aside: You shouldn't be using IE < 7, but that's another battle for another day...

Also: if you're reading this in a feed reader, there's a good chance that JavaScript has been stripped out of the bookmarklet. It's not gonna work like that. Visit the full post to get your TinyURL bookmarklet.

Reset menu sort "weight" in Drupal 6

One of the most amazing and annoying things in Drupal 6 is the menu system. Thanks to a bunch of JavaScript magick, you can drag menu items around to reorder them, create submenus, and so forth. Unfortunately, once you've moved a menu item it no longer alphabetizes itself. If you want things to alphabetize themselves again, you are left with two options:

You can manually alphabetize the menu or submenu every time you change things or add a new menu item, forever and ever and ever. If you're not too keen on that idea, you can edit each of the menu items and reset their weight to 0, which makes them alphabetize again.

Neither option is ideal, so I created a third: this bookmarklet will set the weight of all menu items to 0 in one fell swoop. It also works for resetting block sort order, if you wanted to do that for some reason.

grab the bookmarklet after the jump.