Sunday, February 3, 2008

Where are you photos? Part 5

If you have read my posts on photo storage, you know I have been running Yappa-NG (for years now). Recently, I started tinkering with Gallery2, a php server-based software. The more I tinker with Gallery2 the more I prefer it over Yappa-NG. There appears to be a bigger support from the community to build new skins and modules for Gallery2 than Yappa-NG. Right out of the box, I can see Gallery2 is bundled with more features than Yappa-NG. As I have said earlier though, I do not look for too many features in a photo album. Because it is a photo album, I would like some easy way to upload photos and a really nice skin. Gallery2 does satisfy these two needs.

So, both of my family and friends photo albums have been converted to Gallery2 now. The conversion is (still is) a bit painful.

Because Yappa-NG creates meta-data files in the photo directories, and because I did not want to delete them yet, I imported all the photo directories as a whole into Gallery2. As a result, all the *php, *txt and _data entries got added. I had to go into the MySQL database and clean up the 300+ non-picture entries from Gallery2. In retrospect, I could have changed the file permissions on those files and directories before the import so that the web user cannot import them. Too late for that now.

The second problem I am having is migrating all the album and photo captions from Yappa-NG over. There is no tool for that. Lucky me, there is probably less than 100 entries to copy over. I could write a script and extract and import but it is probably faster to copy and paste, so I am copying-and-pasting the captions over.

Now, I have to learn a bit more about Gallery2. In particular, if I want to rename a photo album directory name on the filesystem, how can I tell Gallery2 what the new name is, because everything in Gallery2 is stored in the MySQL database. I suppose I may have to write a script to do this -- renaming the directory on the filesystem and in the database at the same time. Maybe someone has already written it though.

Well, I am off to breakfast now. Cheers.

No comments:

Post a Comment

Invasion of What?

What are these bugs? I've never seen them before. I saw them at my parents' place the other day. Lots of them in soil or grassy areas.