Forum Moderators: open
I need to add a second gallery on the same page, one gallery above the other and besides the content they work in the same way. I'm calling the same script but have changed the function names to productGallery1 and projectGallery2. I added a second function to the script for the second gallery, below;
---------------------------------------------------------------------
// Product Gallery2
function productGallery2 (imageFile, textFront, textColour, textMaterial)
{
document.getElementById('picture').src = imageFile;
document.getElementById('frontText').innerHTML=textFront;
document.getElementById('colourText').innerHTML=textColour;
document.getElementById('materialText').innerHTML=textMaterial;
return false;
}
---------------------------------------------------------------------
On the gallery page the first gallery works fine, but the second gallery is opening a new page and displaying the swapped image only.
I'm at a loss, any ideas?