More Web creation adventures

Published 3/29/09

So my goal of creating a simple, clean Web site with news, message boards, and a user-filled photo album is getting close.

It turned out to be more complicated than I expected to do something simple: Create a single sign-on for the site that would allow users to post comments to the news, add photos to the gallery(ies), and post messages to the boards.

There’s plenty of software to do all these things — and do them well — but getting the Holy Grail of clean, powerful, and integrated wasn’t straightforward.

I knew the pieces I wanted: WordPress for the overall site, because it’s so easy and powerful (and because I know it well); bbPress for message boards because it can, with some work, integrate with WordPress and because working with its templates is relatively straightforward; and Zenphoto to handle the photo album.

It took a while to get bbPress and WordPress to talk, in large part because of the lack of documentation for bbPress. But I did it. Yay. One sign on gets you permissions for both, and as you bounce between the forums and the main site it remembers you.

Now, on to photos.

Zen and the art of photo galleries

I can’t say enough good things about Zenphoto. It’s, to me, the definitive photo-album-on-a-Web-site package. It’s free, of course, which is staggering in itself.

Zenphoto lets you create as many albums as you want, and put as many photos into each of them as you like. It’s got powerful templates, so you can display a tone of info about each shot (or just the name). It supports the IPTC standard for including info within photos — title, caption, etc.

Once set up, it’s stupidly easy to use. If you have, say, 50 shots from a beach trip, you can create a directory within Zenphoto’s “albums” directory called “2009 Beach Trip.” Then you just upload all your photos there. And you’re done. Zenphoto sees the new directory and automatically creates a new album, then handles creating thumbnails to your specs. All you have to do is dump the files there.

Visitors can browse the albums, leave comments (if you let them), and — if you’ve tagged your photos with keywords — those visitors can creating instant albums of, say, every photo in every album tagged “horse.”

Talk about powerful. That’s why I wanted to use it.

Zenphoto’s downside (if you can call it that) is that it’s single user. It’s not meant to have lots of people with different permissions accessing it. You’re either an administrator (who can add photos) or a user (who can view them).

This could be a challenge, as I wanted to allow users on the site to upload, but I didn’t want them to be administrators and be able to change things.

That’s where Zenphoto’s simplicity comes in.

Easy does it

Here’s how it’s gonna work:

I’m going to create a WordPress page that’s only accessible to registered users. That page will contain a simple FTP upload form that lets users send their files to the site’s server. Specifically, they’ll upload those files to the directory that Zenphoto processes to make albums.

There’s the beauty. Because Zenphoto doesn’t need to be told about new photos — because it simply says, “Look! New pictures within the /album directory! I’d better process them!” — the only permission I need to worry about is registered users’ access to that upload page. If you’re not registered, you can’t see the page, and thus can’t upload images.

This means finding some nice PHP code that will handle the uploads. It will limit file size and only allow JPEG, GIF, and PNG images, which is pretty standard stuff. And presto!, Zenphoto is integrated into the site without worrying about databases and sign-ons.

 

I’m now doing the final look-and-feel integration, to make the different sections of the site (main, forum, photo gallery) look like they’re part of a seamless whole. No one needs to know what’s powered by bbPress, by WordPress, or by Zenphoto; it’s one big, happy site.

And every piece of software used to make it is absolutely free. Wow.

Add to del.icio.us Digg it! Add to Technorati Add to Furl Add to reddit Stumble it!

The Fray


Steven Rumbalski says:

It’s so satisfying when something is both simple and clever. Nice work.

A great way to pay for this free software would be to write up what exactly worked for you in one of the wiki’s for bbPress/WordPress.

March 31st, 2009 at 9:17 AM

Randy says:

This is awesome. I look forward to seeing everything in action.

April 2nd, 2009 at 7:55 AM

Weigh In