You can fetch the currently displayed image number (and then use it elsewhere in your web page) with the SimpleViewer-Pro API.
Each time a new image is selected the svImageChange(index) event is fired. The event data contains the new image index number. The index starts as zero for the first image in the gallery so you may want to add one to find the actual image number which corresponds to the showImageNumber configuration option.
Here is an example which simply displays the image number in a JavaScript alert box. (You could do whatever you like with the number using your own custom JavaScript.)
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>SimpleViewer-Pro Gallery</title>
</head>
<body>
<script type="text/javascript" src="svcore/js/simpleviewer.js"></script>
<script type="text/javascript">
var svAPI;
function svComplete() {
svAPI = document.getElementById('svInstance');
};
function svImageChange(index){
var imageNumber = index + 1;
alert("Current Image: " + imageNumber);
}
var flashvars = {};
flashvars.enableAPI = "true";
var params = {};
params.allowfullscreen = true;
params.allowscriptaccess = "always";
var attributes = {};
attributes.id = "svInstance";
attributes.name = "svInstance";
simpleviewer.ready(function() {
svAPI = simpleviewer.load('sv-container', '100%', '100%', '222222', true, flashvars, params, attributes);
});
</script>
<div id="sv-container"></div>
</body>
</html>
Please note that this is possible only with SimpleViewer-Pro v2 (and can be achieved manually only and not within svBuilder-Pro).
You have posted this in the SimpleViewer-Pro v1 forum and if you are a SimpleViewer-Pro v1 user, then the API will not be available to you and you will need to upgrade your version of SimpleViewer-Pro.
Please see this FAQ regarding the SimpleViewer Pro upgrade policy.
Customers who purchased SimpleViewer Pro v1.9 on or after 9 December 2008 are eligible for a free courtesy upgrade to v2.
If this is the case, then please fill out this form to receive a new link.
Steven Speirs
SimpleViewer Support Team