Guys, stuck here and it's winding me up.
I have a web page, the main header is a group of images that rotate using JS. I now want to add another small group of images to one of the webpages which rotate too. I assumed that I could use the same JS code but the new group of images also shows the main header group rotating. So, I changed all the variable names in the script and that hasn't worked either.
Here is my JS
And here is my HTML
I'm not sure if you can grasp what I'm wanting to do here but hope someone can help. Thanks

I have a web page, the main header is a group of images that rotate using JS. I now want to add another small group of images to one of the webpages which rotate too. I assumed that I could use the same JS code but the new group of images also shows the main header group rotating. So, I changed all the variable names in the script and that hasn't worked either.
Here is my JS
Code:
<!--
var imgShowSpeed = 3000
// Duration of crossfade (seconds)
var crossFadeDuration = 3
// Specify the image files
var Pic = new Array() // don't touch this
// to add more images, just continue
// the pattern, adding to the array below
Pic[0] = 'images/top.png'
Pic[1] = 'images/top1.png'
Pic[2] = 'images/top2.png'
// =======================================
// do not edit anything below this line
// =======================================
var t
var j = 1
var p = Pic.length
var preLoad = new Array()
for (i = 0; i < p; i++){
preLoad[i] = new Image()
preLoad[i].src = Pic[i]
}
function runImgShow(){
if (document.all){
document.images.ImgShow.style.filter="blendTrans(duration=2)"
document.images.ImgShow.style.filter="blendTrans(duration=crossFadeDuration)"
document.images.ImgShow.filters.blendTrans.Apply()
}
document.images.ImgShow.src = preLoad[j].src
if (document.all){
document.images.ImgShow.filters.blendTrans.Play()
}
j = j + 1
if (j > (p-1)) j=0
t = setTimeout('runImgShow()', imgShowSpeed)
}
//-->
<!--
var slideShowSpeed = 3000
// Duration of crossfade (seconds)
var crossFadeDuration = 3
// Specify the image files
var Pic = new Array() // don't touch this
// to add more images, just continue
// the pattern, adding to the array below
Pic[0] = 'images/top.jpg'
Pic[1] = 'images/top1.jpg'
Pic[2] = 'images/top2.jpg'
Pic[3] = 'images/top3.jpg'
Pic[4] = 'images/top4.jpg'
Pic[5] = 'images/top5.jpg'
Pic[6] = 'images/top6.jpg'
Pic[7] = 'images/top7.jpg'
// =======================================
// do not edit anything below this line
// =======================================
var t
var j = 1
var p = Pic.length
var preLoad = new Array()
for (i = 0; i < p; i++){
preLoad[i] = new Image()
preLoad[i].src = Pic[i]
}
function runSlideShow(){
if (document.all){
document.images.SlideShow.style.filter="blendTrans(duration=2)"
document.images.SlideShow.style.filter="blendTrans(duration=crossFadeDuration)"
document.images.SlideShow.filters.blendTrans.Apply()
}
document.images.SlideShow.src = preLoad[j].src
if (document.all){
document.images.SlideShow.filters.blendTrans.Play()
}
j = j + 1
if (j > (p-1)) j=0
t = setTimeout('runSlideShow()', SlideShowSpeed)
}
//-->
And here is my HTML
Code:
<script type="text/javascript" src="scripts\imagerotatefade.js"></script>
</head>
<body onload="runImgShow()";"runSlideShow()">
<div id="wrapper"><!--start wrapper-->
<div id="topbar">
<img src="images/top.png" alt="" name='SlideShow' />
</div>
<div id="header">
<!--start header--><img src="images/top.jpg" alt="" name='ImgShow' /></div><!--end header-->
I'm not sure if you can grasp what I'm wanting to do here but hope someone can help. Thanks
