Actually, you should skip Step 2 and Step 3. And instead change the end of Step 1 from:
Code:
function C_Stp(){this.style.cursor=this.lnk?"pointer":"default";C_Stppd=true;}
function C_Rstrt(){C_Stppd=false}
</script>
<div id="Carousel" style="position:relative">
<img src="placeholder.gif" width="371" height="225">
</div>
<p><font face="Arial" size="-2">Free DHTML scripts provided by<br><a href="http://www.dynamicdrive.com">Dynamic Drive</a></font></p>
to:
Code:
function C_Stp(){this.style.cursor=this.lnk?"pointer":"default";C_Stppd=true;}
function C_Rstrt(){C_Stppd=false}
if (window.addEventListener){
window.addEventListener('load', Carousel, false);
}
else if (window.attachEvent){
window.attachEvent('onload', Carousel);
}
</script>
<div id="Carousel" style="position:relative;width:371px;height:225px;">
</div>
Set the width and height for the div according to the formula at the beginning of the script (here modified to reflect the above HTML and style changes):
Code:
div width:
4 sided: 1.42 * carousel image width + 3 + px
6 sided: 2 * carousel image width + 4 + px
8 sided: 2.62 * carousel image width + 5 + px
12 sided: 3.87 * carousel image width + 7 + px
div height:
carousel image height + 2 + px
Bookmarks