.
Edit: The below solution applies to an outdated version of this script. It will not work with the current version. If you came here looking for this sort of a solution, either continue looking or start a new thread on the topic.
Add to the Image Thumbnail Viewer II script, just below the 'No need to edit beyond here' line:
Code:
///////No need to edit beyond here/////
function findLoaded(){
if(typeof document.getElementById('dynloadarea').getElementsByTagName('img')[0]!=='undefined'){
var theImg = document.getElementById('dynloadarea').getElementsByTagName('img')[0].src
for (var i_tem = 0; i_tem < dynimages.length; i_tem++)
if (theImg.indexOf(dynimages[i_tem][0])>-1)
return i_tem
}
else
return -1
}
function nextImg(){
if (findLoaded()<dynimages.length-1)
modifyimage('dynloadarea', findLoaded()+1)
else
modifyimage('dynloadarea', 0)
}
function previousImg(){
if (findLoaded()>0)
modifyimage('dynloadarea', findLoaded()-1)
else
modifyimage('dynloadarea', dynimages.length-1)
}
Then you can use buttons, images or whatever, example images:
HTML Code:
<a href="#" onclick="nextImg();return false;"><img src="next.gif"></a>
<a href="#" onclick="previousImg();return false;"><img src="previous.gif"></a>
example buttons:
HTML Code:
<input type="button" value="Next" onclick="nextImg();">
<input type="button" value="Previous" onclick="previousImg();">
Edit: The above solution applies to an outdated version of this script. It will not work with the current version. If you came here looking for this sort of a solution, either continue looking or start a new thread on the topic.
Bookmarks