+ 1

Slideshow

how to write a slideshow step by step???

26th Mar 2017, 1:05 PM
Hamidreza Azarshab
Hamidreza Azarshab - avatar
3 Answers
+ 1
Using jQuery 1. Put images inside a div with a class .slider <div class = "slider">....</div> 2. Give the images a class .image-items <img src = "..." class = "image-items" ...in JavaScript jQuery(document).ready(function(){ $(".slider .image-item:gt(0)").hide(); setInterval(function(){ $(".slider > .image-item:first") .fadeOut(1000) .next() .fadeIn(1000) .end() .appendTo(".slider"); }, 10000); 1,000 means the images fade in and out in 1s 10,000 means that the image will change after 10s
26th Mar 2017, 1:47 PM
_n3m9
_n3m9 - avatar
0
That seems easy let me try thanks
26th Mar 2017, 1:51 PM
Hamidreza Azarshab
Hamidreza Azarshab - avatar
27th Mar 2017, 7:25 AM
Ani Naslyan