Showing posts with label gallery2. Show all posts
Showing posts with label gallery2. Show all posts

Friday, July 13, 2007

Photo software mumblings

Adding Statcounter to Gallery2 turned out to be easy. I don't know what about it confused me at first.

Continuing the gallery / photoblog saga, I got an unexpected response to a post on my other blog where I dissed Cheesecake Photoblog. One of its developers invited me to post my bad experiences on Cheesecake Photoblog forum. So I did. We'll see if it results in a productive dialog. Not that I'm really motivated to get Cheesecake Photoblog running on my web site, but I'm a bit curious how can it work out of the box for other people (as they claimed in the forum) and be such a disaster for me.

Sunday, July 08, 2007

I fixed the Gallery! Really fixed it!

I think I have finally fixed the instance of Gallery2 on my web site for real. I am now able to add new images and do pretty much everything with it I did before. I wrote about how I broke Gallery2 here. Since then, I fixed it, but incompletely: it did not allow me to add new pictures. After some more work, I solved that last remaining glitch. What was wrong the first time? The short answer: I had overlooked a table that contains a column that is (I think but am not completely sure) auto-incremented each time a new item is added to Gallery2. That column generates unique IDs for Gallery2 items. Since I did not set its value to the value of the latest item inserted before the upgrade, it was generating ID values that were already "taken" by older items. The full, updated story of how the brokenness came to be and how I fixed it, is here, and yes, I realize that none of the handful of readers of this blog are interested in either the problem or its solution. :-) I'm posting the link here purely "for the sake of completeness", as they say in mathematics. :-)

I also need to find a way to put StatCounter code on my Gallery2 site. It's not obvious where in the Gallery2 bowels its HTML is generated.

However, I am not sure if I want to continue to use Gallery2 at all, or if I want to switch to a different software. My ideal software would have the features of both a photo gallery and a photo blog. (I wrote more about features I look for in photo gallery / blogging software in this blog post.) I tried out two systems that claimed to have such features, Cheesecake Photoblog and Sylverblog, and they both were pathetically unusable. They were so bad I'm not even motivated to write about all the ways they are bad. :-)

Sunday, June 10, 2007

I fixed Gallery -- sort of

Fixed, fixed, fixed! Yay!... was my first thought. (It was tempered by a dose of reality later.) The fix was actually rather simple, and of a different nature than what I thought it would be. That is, it did not come by figuring out what to change in the Gallery2 code. I tried that first, but in the process of debugging the code I hosed it even more than it was already hosed. :-) Basically, I dug myself into a hole, and then dug myself out of it by taking a different route. I won't post the details of the fix here, since they are too tedious for my this blog. I have posted them on my web site instead, so that perhaps someone someday could benefit from my experience.

I was about to celebrate the fix by adding a new, funny image to Gallery. However... trying to upload an image I got an error. So much for joy. Well, at least it is possible to view the images that are already there. That's better than nothing, but still... if it turns out that my fix broke Gallery in a way that makes it impossible to add new pictures, it won't be much of a fix.

Friday, May 25, 2007

Do I need Gallery at all?

Before throwing myself head first into attempt to fix Gallery, I think I should ask myself a question: do I need Gallery at all? Can I do without it? What's the point of having it on my website if I also post all the same pictures on Flickr? Why duplicate the effort? Wouldn't I be better off with just Flickr?

I've thought about it, and compared Flickr and Gallery according to several different criteria. What follows is a long and tedious list that smacks more of accounting than of geekery, and is of interest only to those who are wrestling with similar dilemmas.

1. Data presentation



1.1. Ability to organize images hierarchically



At first, Gallery had an advantage of having hierarchical albums with as many levels of subalbums as you want, whereas in Flickr you could have only one level of "sets". But Flickr recently introduced so-called "collections", which can be made up of sub-collections and sets. Thus it now provides a hierarchical way to organize your images. So Gallery and Flickr are pretty much equal at that point.

The score so far: 1:1

1.2. Ability to present newest images first



Flickr has a significant advantage: it presents your pictures as a (photo)stream -- newest pictures first. (That does not keep you from grouping them into sets and collections.) On the other hand, the only way to access newest pictures first in Gallery (I suppose) is through an RSS feed. And I'm not even sure if Gallery supports RSS feeds! (Though I've read somewhere that it does.) But try to explain to my mother-in-law (who regularly checks my albums for new pictures of Erika) what an RSS feed is, or how to access it! (My own mother, OTOH, took to RSS feeds with gusto after I explained to her what they were.)

The score so far: Flickr 2, Gallery 1

2. Hosting: on my website vs third-party website



One can say that an advantage of Gallery is that it is hosted on my own website, where I have "full control" over my images and data, whereas Flickr is hosted by Yahoo, a big, impersonal, corporation -- and we all know that big corporations are just one step shy of becoming Satan incarnate, and are constantly thinking of ways to harness their customers' data for world domination. :-) Well, the reason I put "full control" in quotes is because I'm afraid the control I have over my data on my website is illusory. First, even though it's "my" website, it is hosted not by me but by a corporation (Dreamhost), and they are the ones who have the actual control over it. Second, performing an upgrade that hosed my software actually caused me to lose control over my data. Loss of control over data comes not just in the form of having your data turned over to FBI, but also in losing ability to manipulate it due to software glitches. Whereas if Flickr hosed its own software, I'm sure they would be working day and night to fix it.

The score so far: Flickr 3, Gallery 1

3. Community aspect



On Flickr I am a part of a big community that occasionally shows it's paying attention to my pictures by way of commenting on them or marking them as favorites. It's nice. The Gallery on my website is not a part of any community. Sure, Gallery has community features: it lets you create user groups, and it lets users add comments to pictures. But not surprisingly, no one has ever created a user account in my Gallery just so as to comment on my pictures. Every time a viewer needs to create an account to participate in something, the probability of their participating falls by about an order or two of magnitude. On Flicr, though, all the Flickr'ites already have accounts, and with those accounts they can participate in all the numerous communities.

The score so far: Flickr 4, Gallery 1

If the score is so much in favor of Flickr, why do I even bother thinking of fixing Gallery on my website?

Here we come to the critical feature that makes it very hard for me to give up Gallery. It's not a feature of Gallery per se as much as a corollary of the fact that I'm hosting Gallery on my web site vs third-party website.

4. Access logs



My web hosting provider allows me to see statistics of who accessed Gallery and when, what images they viewed and where they came from. I am a sucker for access logs. I want to know which IP addresses are viewing my images, and how the viewers found it (referrer pages and search terms). That's 50% of the fun of posting images. I want to know much more than just the view count on a particular image. Because of that, I am not ready to give up Gallery.

You may say, get Statcounter or something like that, and put it on Flickr? Well, Flickr doesn't let you add HTML / Javascript to your photos page, so it's not an option. So, this is the one huge advantage of hosting software on my own website vs Flickr, and that's why I can't give up on Gallery yet.

Wednesday, May 23, 2007

Free software is worth what you pay for it

That's a statement worthy of a troll. So perhaps I should rephrase it more diplomatically. Free software support is worth what you pay for it. Or, to word it even more precisely, free software support by a cheap-ass web hosting company is worth what you pay for it. The company that hosts my web site, Dreamhost, offers a seductive feature: one-click software install for assorted popular free software packages, such as Joomla, phpBB, or Gallery. By clicking a button in your control panel you can initiate an installation process, and after asking a few simple questions, Dreamhost (or rather, its scripts) will do all installation process for you. Neat, huh? I used it to install several software packages on my site, and it worked as advertised.

It lulled me into a false sense of comfort...



For one-click-installable software Dreamhost also offers one-click upgrades. Basically, there is this button in your control panel "upgrade to the latest version", next to each one-click-installable package that you have installed. If a button is there, it's tempting you to click it. After all, why not install the latest version? You want to be "with it", don't you? :-) And Dreamhost provides reasonable precautions against upgrades gone bad: it urges you to back up your database, and it does not destroy the old version, but moves the old directory to .old, assuring you that should you not like the new version, you can revert back to the old one simply by renaming the directory. So really, why not upgrade? Is it any wonder that my finger itched to click that button?

...and then it sprung the trap



So I clicked to upgrade my Gallery installation. And... I don't have Gallery anymore. Or rather, I have a Gallery that throws itself into an infinite loop of URL redirection whenever anybody attempts to view it. It does that because it claims it "can't" "find" the default theme plugin, called Matrix. I put the words "can't" and "find" in quotes, because it's not clear in what sense Gallery is unable to find this plugin. Matrix theme is right there where it's always been, and Gallery debug messages indicate it is indeed able to instantiate the Matrix plugin class. But after that it arrives to a conclusion that the Gallery theme is missing, inactive or incompatible.

Googling this error message and various permutations of its terms didn't yield anything useful or applicable to my situation.

Can't go back to the old version, either



What about the assurance on behalf of Dreamhost that I should be able to go back to the old version of Gallery? (They say it's as simple as renaming the .old directory back to its proper name.) Well, that didn't help -- I'm getting a different error message. Blowing away both the old and the new directories and installing from scratch is not an option either, because I have literally thousands of pictures in Gallery, painstakingly added over the course of two years. I really, really want to fix this install. Dreamhost won't be of help, because they state clearly that they don't support third-party software, and all the installations or upgrades you perform, even the one-click ones, you do at your own risk.

But I think I should still fire off a nastygram to Dreamhost. It's one thing to not support software, but it's quite another to give your users rope to hang themselves with. At the very least they could have tried out the one-click upgrade themselves, observed that it leads to a disaster, and issued a warning to users. But I've been too demoralized to fire off nastygrams.

Of course, since this is an open source program, its source code is available to me, so in theory I should be able to debug it. In theory. Given plenty of spare time. If I go that route (since I don't have many other options at this point), at least I'll be able to get a lot of blogging mileage out of it, in the spirit of Eric Raymond's CUPS rant :-) (I won't put tedious details in this blog, though.)