View Full Version : Image Thumbnail Viewer II

07-26-2005, 07:29 PM
Image Thumbnail Viewer II

Script works great -love it! Just a question though, does anyone know how to have one of the images automatically load on page load (you can set the large image to be shown via onClick or OnMousemover of the thumbnails -- but I want to have one in the empty "large" spot, then have the OnMouseover for the rest of the thumbnails) I tried changing the "onClick" to "onLoad" but that didn't work...I'm don't know how to write code, I only know how to mess around in it.

Any help would be greatly appreciated!


07-26-2005, 08:30 PM
Two choices:

1 ) Put the image tag of the desired image inside the 'load' area:

<div id="dynloadarea" style="width:80px;height:225px"><img src="myimage.jpg" border="0"></div>
2 ) Make loading your preferred image part of the onload event for the page:

<body onload="modifyimage('dynloadarea', 0)">The '0' refers the dynimages[x] number of the image in the dynimages array.

07-26-2005, 08:58 PM
Hi John,
I can't thank you enough -- that worked perfectly!

You can check it out if you're so inclined: :) http://www.royalwindowcoverings.com/fabricators/


07-27-2005, 03:29 AM
Well, but you have two problems still, at least. You are only allowed 1 body tag (actually you can have as many as you want but, all except for the first will be ignored). So, get rid of the one you just added and make the one you already had include the new info:

<body bgcolor="#E9E7EB" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="MM_preloadImages('../images/nav2.gif','../images/nav_aboutus_2.gif','../images/nav_products_2.gif','../images/nav_where_2.gif','../images/nav_custcare_2.gif','../images/nav_resources_2.gif','/images/nav_news_2.gif','../images/nav_contact_2.gif');modifyimage('dynloadarea', 5)">The other problem is that:

http://www.royalwindowcoverings.com/images/comp_med.jpg (http://www.royalwindowcoverings.com/images/comp_med.jpg)

is not there. There is a:

http://www.royalwindowcoverings.com/images/components.jpg (http://www.royalwindowcoverings.com/images/components.jpg)

but, I am not sure if it is what you want displayed there.