Writing a WordPress Plugin
When Kim and I first started out blog, we poured over many WordPress Themes, trying to find the right one that suited our needs and that we liked the looks of. One of the things that Kim really wanted was a “Photostream” of recent pictures, similar to the one on Matt Logelin’s Blog. That Photostream uses a Flickr account, and we just wanted to upload the pictures directly into our blog posts. I couldn’t find a WordPress Theme that had such a feature, but we settled on a theme with a “Recently Added” pictures feature. But this didn’t quite meet the requirements of my #1 user. I ended up finding a plugin called Post Image Gallery that had a lot of the features that we wanted, but still required a lot of tweaking to make it work the way that we wanted.
So what you see on our current blog home page is my tweaks to the Post Image Gallery plugin. And every time I look at our blog it bugs me. Mainly because the images in the photostream aren’t cached or resized. They are the actual images from our recent blog posts which are resized on the browser side. What does that mean? It means really slow load time! And that’s what bugs me. That, and the fact that I’ve had to tweak (aka hack) the code in Post Image Gallery to get it to do what I want.
So I’ve undertaken writing my own plugin to improve on the features availible in the Post Image Gallery plugin. I’m calling it “Kim’s Photostream” since most of my requirements come from Kim. When learning any new technology, there’s a lot of learning to be done. It took me a week just to get the upgrade process working with the WordPress.org Plugin Site. But I’m making progress. I’ve set up my plugin in the WordPress Subversion Repository. I’ve figured out how to search through all the recent blog posts and find the images in them. Next up on my list is creating thumbnails for those images (and cleaning up thumbnails that are too old) and finally creating a function to display Kim’s Photostream.
I think I’ve got a pretty good design, and I think that in a few weeks, I can have version 1.0 of Kim’s Photostream Plugin complete. A couple of weeks?!? Yeah, well, I have a full time job. So, in the mean time, stay tuned, and hopefully soon, I can demo the Plugin for you. And soon I can replace the Post Image Gallery with Kim’s Photostream on our blog!