Twitter Quick Reply


A quick bookmarklet that I made for Asa Dotzler. If you've ever visited a tweet, on Twitter, directly, and had wished to immediately reply to its author you probably found it to be quite convoluted (typically this is the case if you subscribe to services like Summize or Tweetscan. It usually involves copying the username, visiting the reply screen, and then typing/pasting in the relevant parts to make the @reply. Instead you can just use the following bookmarklet to make that easy.

javascript:window.location=window.location.href.replace(/(com.)([^.\/]+).*/,"$1home?status=@$2+");

First, Drag this to your bookmark bar: Twitter Reply

Second, visit a tweet: http://twitter.com/jeresig/statuses/841204003

Then hit the bookmarklet and you should be taken to the reply screen with "@jeresig " (or whatever the appropriate username is) already pre-filled in. Enjoy!

P.S. As a bonus it maintains the http/https URL protocol, as well.

Posted: June 24th, 2008 · Tags: twitter, javascript

5 Comments

  1. Michael S. (June 24, 2008 at 5:28 pm)

    The "drag link to bookmark bar" doesn't work in Google Reader (and most likely other web-based readers): it neuters "javascript:" links.

  2. John Resig (June 24, 2008 at 5:44 pm)

    @Michael: Eh, not much that I can do about that. Worst case you can just copy the code shown above and paste it in to a new bookmark.

  3. Alan Hogan (June 24, 2008 at 8:07 pm)

    Opera 9.5 users, if you want this in your Nav/Address bar, hold Shift while dragging.

    Thanks for sharing, John.

  4. NealAbq (June 26, 2008 at 10:36 am)

    You can put that "javascript:.." URL right in the address bar (FF3). Just occurred to me. 'N now im writing tweetish comments.

  5. patty (July 28, 2008 at 4:54 pm)

    Are you able to make a bookmarklet for twitter so we can easily send a site to twitter and add a short description?

Leave a Comment

Note: Wrap all of your code blocks in <code>...</code> and replace < and > with &lt; and &gt;, respectively.

Current Projects

jQuery JavaScript Library

jQuery

Comprehensive DOM, Event, Animation, and Ajax JavaScript Library.

Recent Projects

Pro JavaScript Techniques

JavaScript Book

The best techniques for professional JavaScript. Published by Apress.


Hosting provided by the cool dudes at Engine Yard.