/***********************************************
* Image Thumbnail Viewer II script- c Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Visit http://www.dynamicDrive.com for hundreds of DHTML scripts
* This notice must stay intact for legal use
***********************************************/

//Specify image paths and optional link (set link to "" for no link):
var dynimages=new Array()
dynimages[0]=["products/storage/TopMountWastebasket.jpg",""]
dynimages[1]=["products/storage/BasePantryPullout.jpg", ""]
dynimages[2]=["products/storage/WoodTieredCutleryDivider.jpg", ""]
dynimages[3]=["products/storage/LazySusan.jpg", ""]
dynimages[4]=["products/storage/BasePotsPansStorage.jpg", ""]
dynimages[5]=["products/storage/RolloutTrays.jpg", ""]
dynimages[6]=["products/storage/MultiStoragePantry.jpg", ""]
dynimages[7]=["products/storage/SpiceDrawerInsert.jpg", ""]
dynimages[8]=["products/storage/SinkBaseDoorStorage.jpg", ""]
dynimages[9]=["products/storage/TallPantryPullout.jpg", ""]

//Added by eling
var tags=new Array()
tags[0]=["Top Mount Wastebasket"]
tags[1]=["Sink Base Door Storage"]
tags[2]=["Wood Tiered Cutlery Divider"]
tags[3]=["Lazy Susan"]
tags[4]=["Base Pots and Pans Storage"]
tags[5]=["Roll-out Trays"]
tags[6]=["Multi-Storage Pantry"]
tags[7]=["Spice Drawer Insert"]
tags[8]=["Base Pantry Pullout"]
tags[9]=["Tall Pantry Pullout"]

//Preload images ("yes" or "no"):
var preloadimg="yes"

//Set optional link target to be added to all images with a link:
var optlinktarget=""

//Set image border width
var imgborderwidth=0

//Optionally, change 1.0 and 0.7 below to affect Wipe gradient size and duration in seconds in IE5.5+:
//var filterstring="progid:DXImageTransform.Microsoft.GradientWipe(GradientSize=1.0 Duration=0.7)"
var filterstring="progid:DXImageTransform.Microsoft.Fade(duration=0.7)"

///////No need to edit beyond here/////

if (preloadimg=="yes"){
for (x=0; x<dynimages.length; x++){
var myimage=new Image()
myimage.src=dynimages[x][0]
}
}

function returnimgcode(theimg, thetag){
var imghtml=""
if (theimg[1]!="")
imghtml='<a href="'+theimg[1]+'" target="_new">'
//target="'+optlinktarget+'">'
imghtml+='<img src="'+theimg[0]+'" border="'+imgborderwidth+'" alt="'+thetag[0]+'">'
if (theimg[1]!="")
imghtml+='</a>'
return imghtml
}



function modifyimage(loadarea, imgindex){
if (document.getElementById){
var imgobj=document.getElementById(loadarea)
if (imgobj.filters && window.createPopup){
imgobj.style.filter=filterstring
imgobj.filters[0].Apply()
}
imgobj.innerHTML=returnimgcode(dynimages[imgindex], tags[imgindex])
if (imgobj.filters && window.createPopup)
imgobj.filters[0].Play()
return false
}
}

