[pmwiki-users] DB lookup of picture path

Henrik Bechmann henrik at bechmannsoftware.com
Mon Feb 20 13:39:09 CST 2006


I'm using coppermine as a photo gallery, which unfortunately doesn't 
understand the concept of a repository (filing pictures by named 
physical location). Instead it records pictures by (logical) album name 
and picture name.

I want to allow my users an easy way to map pictures from this database 
to PmWiki pages, and I wonder if anyone has any advice on an approach.

An obvious approach would be to create a directive like

(:galleryimage albumname picturename:)

and have the directive do an SQL query on the database, and substitute 
the picture url for the directive.

I wondered if there was some way to use the farmmap/textmap feature, so 
that the user could do something like

GalleryImage:?albumname&picturename.jpg

Where GalleryImage: would be mapped to

getpicturepath.php?album=albumname&picture=picturename.jpg

or some such.

Performance is an issue of course, and again any advice on that score 
would be welcomed.

Any thoughts, hints, ideas, guidelines, examples?

Thanks,

- Henrik

-- 

Henrik Bechmann
www.osscommons.ca
www.bechmannsoftware.com
Webmaster, www.dufferinpark.ca





More information about the pmwiki-users mailing list