Removing an invalid album in Gallery 1.x

jph

Joined: 2005-04-29
Posts: 12
Posted: Wed, 2008-07-09 18:45

Gallery 1.x situation:

Logging in as administrator, you see the message: Attention Gallery Administrator! Gallery has detected the following [number] invalid album(s) in your albums directory.

I really think that this topic should be in the Gallery 1.x FAQ, but I could find no reference for it there or in the documentation or by searching the forum.

Here's my [draft] general procedure for removing "invalid" albums. It's somewhat technical. I had to use it this morning again. The online Gallery Support Forum was of limited help in figuring out these steps awhile back. Basically, the album.dat file in each case gets corrupted or left empty [0 bytes], which may happen during an aborted upload or server glitch.

1. Using ftp, move all albums flagged as invalid to a backup folder outside the albums directory [folder], if you wish to later re-upload any of the photos [if any]. Or, delete the invalid album folders using the Admin options > Validate albums > [action] available in Gallery 1.5.3 and later.

2. In Gallery, create a new album [which can be deleted later].

3. Using ftp, make a copy of that album [folder] and rename it to the name of one of the invalid albums [in the albums folder].

4. In Gallery, using album actions, check that the description of the target album is blank and the title has an "Untitled" value. Otherwise, some adjustment may be made by directly editing the album.dat file, noting its plain text format of parameter name and string "s" length and value, e.g., for "title" and "description" items.

5. In Gallery, you should now be able to click on the "invalid" album in the albums list and not get an error. You can then use the Album Actions to delete the album in question.

Note: Sometimes other invalid albums will need to be deleted before a particularly troublesome album. When the album shows a "Viewed: 1 times" status, using Gallery, the album should be able to be deleted.