Thank you. To be honest someone else built my site for me I only know how to add new pages and link them in.
Are you saying I can just copy paste this section into my index page (replacing the blue with my own links to the images I want in the slideshow)? I'll certainly give it a go if it's that simple thanks!
Paste the code below (down to the ending </script> tag) in your page, directly before the closing </head> tag.
<style>
/* css to hide image slides on page load */
.slide-show img {
position: absolute;
display: none;
}
</style>
<!-- link to the jQuery library -->
<script src="http://code.jquery.com/jquery-2.1.1.js"></script>
<script>
<!-- slideshow script -->
$(document).ready(function() {
$(".active").show();
setInterval(function(){ Next($('.slide:visible'))}, 2400);
});
function Next(slide) {
slide.fadeOut();
if(typeof slide.next().attr('src') !== 'undefined') {
slide.next().fadeIn();
} else {
$('.active').fadeIn();
}
}
</script>
You must have a container in your page where your current images get written to by the script you posted?
Find that container and give it a class of slide-show:
<div class="slide-show">
</div>
<!-- end slide-show -->
Then add the images to the slide-show <div> giving them a the class 'slide' and 'active' as below: (I assume your slideshow images are in a folder named 'index')
<img class="slide active" src="index/slide1.jpg"/>
<img class="slide" src="index/slide2.jpg"/>
<img class="slide" src="index/slide3.jpg"/>
<img class="slide" src="index/slide4.jpg"/>
<img class="slide" src="index/slide5.jpg"/>
<img class="slide" src="index/slide6.jpg"/>
So you end up with:
<div class="slide-show">
<img class="slide active" src="index/slide1.jpg"/>
<img class="slide" src="index/slide2.jpg"/>
<img class="slide" src="index/slide3.jpg"/>
<img class="slide" src="index/slide4.jpg"/>
<img class="slide" src="index/slide5.jpg"/>
<img class="slide" src="index/slide6.jpg"/>
</div>
<!-- end slide-show -->