Photoblog navigation

Inspired by Dunstan’s post on photoblog navigation and the ensuing discussion, I made some changes to the way The Life of Jalo works. The code was uploaded sometime – much too late – last night, so if you frequent LoJ you might have already noticed them.

First I inserted some JavaScript code to enable keyboard navigation. The code that accomplishes this was taken directly from Eric Meyer’s S5 slideshow system. I only changed which keys do what. So now in the daily or monthly index views you can use ‘n’ or PageDown and ‘p’ or PageUp to navigate to the next/previous image/month respectively. The keys ‘f’ and ‘l’ take you to the first or last image/month… All this is enabled by a few lines of code (use view source to get it, if interested) and helps the usability of the site significantly.

I’d been thinking of inserting a calendar that would have a link to for each day a image is available to allow users to jump over several pictures, but it felt slightly silly since LoJ will (hopefully) be updated every day. Some time spent browsing other similar sites left me with the decision to use the directory view of Daily Oliver. Alas, Oliver no longer, after the Textpattern update, supports the directory view. After a day of hacking with PHP (while watching the television) the code was completed and tested. A slight change to the .htaccess URL rewriting rules and all was set to go. If anyone is interested, I could post the code that creates LoJ somewhere. Leave a commet if you’re interested.

On a related note, LoJ now has Atom, RSS 1.0, and RSS 2.0 feeds. It was finally time for me to read the specs on these languages and figure out what they have eaten. It was fun and all of the feeds validate. Sorry, the images aren’t included in the feeds, just links to them. We want to know which images get viewed the most and letting you suck them through feed readers wouldn’t be really helpful for us in figuring that out.

P.S. Any LoJ followers interested in leaving comments?

Leave a Reply