I've got an existing website written in PHP that uses some images. Those images are currently managed in a G1 installation. I access them by going directly to the local album through the filesystem (e.g. <img src="albums/foo/aaa.jpg"). The pictures to be displayed are often controlled via a list of image filenames (e.g. album1/aaa.jpg).
Since G2 stores the thumbnails separately from the original images, and because I now want to be able to access the comments stored in the gallery, I need to find out how to programmatically do the following:
- Given an identifying datum about an image (preferably the album/filename, but an ID of some sort would work), obtain size and comment information about it, the thumbnail, and any intermediary scaled images.
- Given an indentifying datum about an image, retrieve that image for display.
Can somebody provide me with a pointer to any sample code that does this? I've looked in the autogenerated API docs, but I'm floundering around...there's very little context there.
Thanks!
Posts: 32509
some existin integrations do that already, e.g. mediawiki, wp and joomla. take a look at their code please.
(that to say, it isn't documented, but you can learn from examples)