Log in

View Full Version : Navigating JS gallery by clicking on images



samslystone
04-19-2013, 10:08 AM
Hi All

I have another question regarding the following website:

http://www.catherinehyland.co.uk/

The user would like to be able to have the added option on the work/gallery page of clicking through the images by clicking on the images. Currently the only way to move through the images is by using the numbers below and the next/previous buttons.

Any comments greatly appreciated

All the best

Samuel

vwphillips
04-19-2013, 02:14 PM
at the bottom of the page



var imgs=document.getElementById('cf7').getElementsByTagName('IMG');;
for (var z0=0;z0<imgs.length;z0++){
imgs[z0].onclick=function(){ Next(1); }
}

samslystone
04-19-2013, 04:58 PM
Simple as that! Thank you so much Vic, that is a great help.

All the best

Samuel