There's no need to copy the galleries.php file, as you can set up redirections to make modules appear to run from multiple zones. To do this, go to 'Structure' in the Admin Zone, then 'Redirects'. If you had a zone called 'test' you'd set up a transparent redirection from 'test':'galleries' to 'site':'galleries'. If you then link to galleries from the test zone (either by using a URL that suggests that zone, or by using the page-link test:galleries), you'll be viewing it entirely from your test zone.
How to have separate galleries in different zones is a separate issue to making the galleries module run in different zones. This can be achieved by linking to the galleries module using ocPortal's "virtual roots" feature. The reality is that you'll have one tree structure of galleries, but the virtual roots system will hide it.
The easiest way to do this is as follows…
- set up galleries for each zone you want galleries in, each coming off your root gallery.
- add your content to these galleries
- browse into one of your galleries. You'll see it appearing as the system sees it by default - that is, you'll see the full navigation structure of the galleries in the breadcrumbs (the breadcrumbs are those horizontal chevron-split links towards the top right of most screens).
- look closely at your breadcrumbs whilst you're still in the gallery (not viewing an image, in the gallery). Assuming you're logged in as staff you'll see that the last item in the breadcrumbs is a link, and if you think, it doesn't need to be a link because you're already looking at the gallery it's linking to. This is the twist – if you click the link, you'll see that this seemingly redundant link is actually special – after clicking it, the breadcrumbs have reduced, making it look like this gallery is the root gallery. You saw this extra link because you were staff, you're regular member's don't see it.
- look at the URL. You'll see that this effect is achieved by some extra information embedded into it. You can take this URL and put it onto the menus as you require it (modified for the right virtual root, and the right zone, as appropriate).
Was I helpful?
- If not, please let us know how we can do better (please try and propose any bigger ideas in such a way that they are fundable and scalable).
- If so, please let others know about Composr whenever you see the opportunity or support me on Patreon.
- If my reply is too Vulcan or expressed too much in business-strategy terms, and not particularly personal, I apologise. As a company & project maintainer, time is very limited to me, so usually when I write a reply I try and make it generic advice to all readers. I'm also naturally a joined-up thinker, so I always express my thoughts in combined business and technical terms. I recognise not everyone likes that, don't let my Vulcan-thinking stop you enjoying Composr on fun personal projects.
- If my response can inspire a community tutorial, that's a great way of giving back to the project as a user.