I have a website for my artwork. I want to have a simple image swap when the user clicks on a thumbnail image. It works fine when I use 'onmouseover', however, I want to have the user click on the image, instead of holding the mouse over it.
When I use 'onmouseup' it also works, but it zooms back up to the top of the page each time the user clicks on an image. Just wondering if there is a way to prevent this.
You can see my website here www.schmidt-gallery.com/3d_design/3d_design.html
Right now it is using 'onmouseover' but if you scroll down a bit, and clicko on a thumbnail, you will get the same effect, where it zooms up to the top of the page.
use onclick on the image object
<img src ='' onclick='...'>
where onclick is like your onmouseober.
if you want the cursor to be hand just set it for te image
in onmouseover ( ='this.style ... ' ).
<a href="#" onmouseover="document.sub.src='images/sub_09.jpg';" onclick="return false;" >
<img border="0" width = "50" src="images/2_sub_09.jpg"></a>