I've seen in the Gallery 2 Roadmap that one of the features is "Allow multiple files per item (multiple "Views" / perspectives)."
I need this feature for one of my clients in the upcoming weeks. Is there a way to do this already in Gallery2? If not, is there a workaround that I can implement?
Posts: 4338
Gallery2 development was terminated more than a year ago. As far as I know, no, that feature was never implemented.
Posts: 5
Is that feature in Gallery3 then? Is it easy to write a workaround for Gallery 2 or is it impossible under the structure?
Posts: 4338
Almost certainly not, and I doubt there are any plans to implement it, given what I know about the philosophy of G3 (small, mean on resources, and easy for *you* to extend). But somebody may be sufficiently interested in the feature (you?) to write the code for it...
Everything is possible with G2, but nothing is "easy". How good is your php?
Posts: 5
My PHP skills are fair as I'm reasonably new to it. I'm more experienced in in other languages. Do you know which pages I would have to modify or is it a trail and error process?
Thanks for you help anyway.
Posts: 6138
Multiple views/files per item.
Isn't that what we call an album?
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 5
An example of what I want to achieve is here http://www.henrijosef.com.au/bridesmaid-dresses-page-1.php#top. I want each thumbnail within an album to have 2 photos associated with it.
Posts: 4338
OK. So first of all you need to come up to speed with the relevant parts of the G2 framework. Things that are in Gallery albums are extensions of the Object GalleryItem, (hence GalleryPhotoItem) so I guess off the top of my head you'd need to create a new GalleryMultiplePhotoItem or some such. So you'll have to be 100% with how GalleryItems work, and how and where the GalleryPhotoItem interacts with the databse. That means being 100% GalleryEntities, Maps and so forth. (these names may mean nothing to you now, but you will know them like old friends by the time you're done.)
If your php skills are only 'fair' I would budget 3 to 6 months of studying and testing before actually starting on your project. You should pick something else to try first, as your first effort in G2 will probably be a disaster (the code in the first module I ever wrote makes me shudder now, but the second one was much better).
The G2 development documentation (such as it is, which isn't much) is here:
http://codex.gallery2.org/Development
And the complete, detailed Core API is here:
http://gallery.menalto.com/apidoc/GalleryCore/Classes/GalleryCoreApi.html
The GalleryPhotoItem is here:
http://gallery.menalto.com/apidoc/GalleryCore/Classes/GalleryPhotoItem.html
The code for it you'll find in modules/core/classes/GalleryPhotoItem.class
Obviously you'll need to put the code for your new Class inside a module, so it can be installed/removed without hacking core code (so the rest of the community can benefit from your work) so that means coming up to 100% on the Gallery module structure too.
There may also be other ways to extend G2 to do what you want apart from a new Item type; given that it was in the Roadmap it means that at least one of the developers had an idea for how to implement it. So you could email the gallery-devel mailing list and ask the development team for a five-line suggestion on how they were planning to implement it. If they do suggest a new GalleryItem subclass then I have some code I can send you that might help.
By the way, the link in your post is broken.
Posts: 6138
I could create that same effect with my jQuery mediaBlock without altering gallery.
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 5
That would be great. Do you have an example gallery with my feature implemented?
Posts: 6138
Since I have no interest in that feature - no.
I imagine your gallery organized like this:
Hats Coats - Winter - Fur - item1 - view1 - view2 - item2 - view1 - view2 - item3 - view1 - view2 - item4 - view1 - view2 - Denim - Wool - Spring - Summer - Fall Boots Gloves ...-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2