Gallery 2 is a great photo gallery script. It has some SEO issues though.
These tip is just from a quick glance at a newly installed Gallery 2. They have not been tested on an active site.
One issue is that the root of Gallery, e.g., http://example.com/, does a 302 redirect to http://example.com/main.php. 302 redirects from the home page are not good. You can change that behavior in the index.php file.
Change this:
$phpVm->header('Location: ' . $urlGenerator->makeUrl($path));To this:
$phpVm->header('Status: 301 Moved Permanently');
$phpVm->header('Location: ' . $urlGenerator->makeUrl($path));Then, only link to http://example.com/main.php from other internal pages. It's not a perfect solution, but it's quick and all I had time for on my test installation.
Also, if you are using clean URLs on Gallery 2, you might want to block the dynamic pages:
User-agent: *
Disallow: /*?
UPDATE: don't add that to your robots.txt. On further investigation Gallery 2 is not good for an SEO-conscious Web site. There are many 302 redirects throughout it. The URLs are not good. Gallery 2 is a great system for a personal photo gallery, but don't use it if you need a SEO'd photo gallery.
Did you find this post helpful? Leave a comment below, and subscribe to my RSS feed.
Comments
SEO for Gallery2
I thought you might find this tutorial on Gallery2 SEO useful.
Thirteen Ways To Add SEO To Gallery2: http://gallery.menalto.com/node/70008