This solution works equally well with both Juicebox-Lite (the free version and Juicebox-Pro).
Try the following:
(1) Create two galleries and save them in folders named 'gallery1' and 'gallery2'.
(2) Upload the two complete gallery folders (not just the contents) to the root directory of your web space (usually into a directory named 'public_html' or 'htdocs').
(3) Create an HTML web page using the following code, upload it to any location on your web server and open it in a browser.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" id="jb-viewport" content="minimal-ui" />
<script type="text/javascript" src="/gallery1/jbcore/juicebox.js"></script>
<script type="text/javascript">
function loadGallery(base) {
new juicebox({
baseUrl: base,
containerId: "juicebox-container",
galleryHeight: "400",
galleryWidth: "600"
});
}
$(document).ready(function() {
$('.gallery').click(function() {
var base = '/' + jQuery(this).attr('id') + '/';
loadGallery(base);
});
loadGallery('/gallery1/');
});
</script>
<title>Test</title>
</head>
<body>
<div id="links">
<input id="gallery1" class="gallery" type="button" value="Gallery 1" />
<span> </span>
<input id="gallery2" class="gallery" type="button" value="Gallery 2" />
</div>
<div id="juicebox-container"></div>
</body>
</html>
I've tried to keep the code as basic as possible so that you can see what is going on.
You can change the HTML buttons for text or images if you like, as long as you give each link a class="gallery" attribute and and id with the name of the corresponding gallery folder.
For each additional gallery, all you would do is upload a new gallery folder to the root of your web space and add a line of code such as:
<input id="gallery_folder_name" class="gallery" type="button" value="text_for_button" />