I currently have the following code that replaces a big image when a thumbnail is clicked:
Javascript:
img1 = new Image();
img1.src = '{$smarty.const.dir_images}/l_{$this_page.image1}';
img2 = new Image();
img2.src = '{$smarty.const.dir_images}/l_{$this_page.image2}';
Thumbnail HTML:
<a href="javascript:document['mainimage'].src = img1.src; javascript:void(0);"><img src="{$smarty.const.dir_images}/t_{$this_page.image1}" title="" alt=""/></a>
<a href="javascript:document['mainimage'].src = img2.src; javascript:void(0);"><img src="{$smarty.const.dir_images}/t_{$this_page.image2}" title="" alt=""/></a>
Large Image HTML:
<img id="mainimage" name="mainimage" src="{$smarty.const.dir_images}/l_{$this_page.image1}" title="{$this_page.image1text}" alt="{$this_page.image1text}" />
What I want to do is not only change the large image source when the thumbnail is clicked but the alt & title tags as well.
Thanks in advance