If you want to prevent browsers from caching your gallery's dynamically-generated XML file, then try adding a unique query string (e.g. the current time which will be different each time the browser loads the page) to the configUrl option in your gallery's embedding code.
For example:
configUrl : "config.php?nocache=" + new Date().getTime(),
If you really want to add a refresh button to your web page, then you could use something like the following (which would overlay a 'refresh' link in the top left corner).
<div id="refresh" style="background-color: rgba(0,0,0,0.5); color: rgba(255,255,255,1); cursor: pointer; font-size: 20px; left 0px; padding: 4px; position: absolute; top: 0px; z-index: 9999;">
<span onclick="javascript: window.location.reload(); return false;">Refresh</span>
</div>
If you wanted the 'refresh' link to be displayed only on mobile devices, then you could check to see what screen mode Juicebox is using (via the Juicebox-Pro API getScreenMode() method) and display the 'refresh' link only in Small Screen Mode.
<!DOCTYPE html>
<html lang="en">
<head>
<title>Juicebox Gallery</title>
<meta charset="utf-8" />
<meta name="viewport" id="jb-viewport" content="minimal-ui" />
<meta name="description" content="This is a Juicebox Gallery. Get yours at www.juicebox.net" />
<style type="text/css">
body {
margin: 0px;
}
#refresh {
display: none;
}
</style>
</head>
<body>
<!--START JUICEBOX EMBED-->
<script src="jbcore/juicebox.js"></script>
<script>
var jb = new juicebox({
containerId: 'juicebox-container'
});
jb.onInitComplete = function() {
if (jb.getScreenMode() === 'SMALL') {
document.getElementById('refresh').style.display = 'block';
}
};
</script>
<div id="juicebox-container"></div>
<!--END JUICEBOX EMBED-->
<div id="refresh" style="background-color: rgba(0,0,0,0.5); color: rgba(255,255,255,1); cursor: pointer; font-size: 20px; left 0px; padding: 4px; position: absolute; top: 0px; z-index: 9999;">
<span onclick="javascript: window.location.reload(); return false;">Refresh</span>
</div>
</body>
</html>
(onInitComplete() and getScreenMode() work in Juicebox-Lite as well as in Juicebox-Pro.)
I hope this helps.