A WordPress Plugin: Image URL Returner

There are a number of programs you can use to create entries for a WordPress blog. Now that I own an N900 phone, I’d like to use the excellent MaStory client. This works fine, unless you want to upload photos.

When you upload a photo, WordPress automatically make smaller versions of the image (of configurable size). Unfortunately it doesn’t tell the client what the URLs to these resized images are. I’ve created a patch to WordPress that returns the URLs but it has missed the cut off for 3.0 so it’ll be some time before it gets included. In the mean time, I’ve created a tiny plugin that does the same thing.

This plugin is not useful to you at all unless you use a blogging client that makes use of it. The only client I intend to alter is MaStory so I’m imagining this plugin will not be used by a lot of people.

To use the plugin:

  1. Download the plugin (It’s now available from its plugin page on wordpress.org as well)
  2. Upload `ImageURLReturner.php` to the `/wp-content/plugins/` directory
  3. Activate the plugin through the ‘Plugins’ menu in WordPress
  4. Use a blogging client that makes use of the plugin – this is the hard bit – there is no such client at the moment. I have created a patch for MaStory though.

Update: (Sept 11th 2010) I’ve just uploaded a new version (0.2) that handles images with duplicate names. Thanks to the people who pointed out the bug.