Drupal quick-post bookmarklet

Perhaps I’m being dense, but I’ve spent about four hours today trying to get a decent quick-post bookmarklet set up for Drupal. (And no, this isn’t a version 5 problem, I’ve never had such a thing.)

While I found many sites that had advice on crafting an appropriate URL, none of them mentioned that I needed the prepopulate module in order for any of them to work.

Additionally, only one person mentioned that I needed to put “edit[body_filter][body]” into the URL string rather than the more commonly suggested “edit[body]”.

So, in interests of saving people time, those are the two tricks to getting this to work. I’ve attached my javascript as a text file (it assumes you’re using Markdown for formatting, adjust as necessary for HTML) since it’s rather ugly to paste it inline.

I hope this helps somebody. I know I’ve wasted way too much time on it already.

Twitter, Facebook

Written on March 2, 2007