I'm new to the Koha community and am looking for details about using Koha to catalog images, or associating an image with each catalogued record.
I can't advise you on cataloging images, but I can tell you how we came up with a way to associate images with item types in search results and with individual titles as well. The key is to use Koha's templating system to do the work for you. We wanted to have an image associated with each item type in the catalog (book, video, dvd, etc.). A bug in the current version prevented us from using the mechanism at work in HLT's OPAC (http://opac.library.org.nz/cgi-bin/koha/opac- detail.pl?bib=12180), but by naming each image according to the corresponding item type, we were able to put this in the template: <img src="<TMPL_VAR NAME='themelang'>/images/<TMPL_VAR NAME="itemtype">.gif" alt="" /> The templating system replaces '<TMPL_VAR NAME="itemtype">' with "Book on Tape" or "Videorecording", and that points the image tag to the right file. See it in action here: http://66.213.78.60/cgi-bin/koha/opac- searchresults.pl?type=opac&keyword=moon+is+a+harsh+mistress The same function will allow us to retrieve book cover images for individual titles. We'll save with images with filenames corresonding to the ISBN of the title. Then when the item detail screen is pulled up, the ISBN can be used in the image tag to pull the right image file (I know I first saw this method on a German Koha installation--maybe someone remembers the address of that?). The current barrier to using this method for us is the fact that if there is no image for a particular ISBN, you get a broken image. If we can get that ironed out, we can start going with it. I hope that helps with at least part of your question. -- Owen ---- Nelsonville Public Library http://www.athenscounty.lib.oh.us
On 2004-01-21 17:34:36 +0000 Owen Leonard <oleonard@athenscounty.lib.oh.us> wrote:
no image for a particular ISBN, you get a broken image. If we can get that ironed out, we can start going with it.
With the right apache config, maybe you could use an .htaccess file in the images dir which says: ErrorDocument 404 /path/to/some/file.png (for you should use PNG instead of GIF if possible). I'd like to hear if anyone makes that work. -- MJR/slef My Opinion Only and possibly not of any group I know. Please http://remember.to/edit_messages on lists to be sure I read http://mjr.towers.org.uk/ gopher://g.towers.org.uk/ slef@jabber.at Creative copyleft computing services via http://www.ttllp.co.uk/
participants (2)
-
MJ Ray -
Owen Leonard