image slider
Jun 06, 2016
Hi All I have an image slider that works, however i have four lots of 170 images and I want to make it easier than having to replicate this 170 times.
I have made a HTML file and put it in the project with a javascript slider which is a lot easier to use but i'm having problems preloading the images as the slider jitters when scrubbing as it downloads the images as it requires them. I have tried various image preloader scripts, none of which seem to work.
////////////////such as this//////////////////
$.preloadImages = function() {
for (var i = 0; i < arguments.length; i++) {
$("<img />").attr("src", arguments[i]);
}
}
$.preloadImages("hoverimage1.jpg","hoverimage2.jpg");
////////// or this /////////
jQuery(function($){
$('.slideshow img') .each(function(index, element) {
(new Image()).src = $(element).attr('src');
});
});
Does anyone have any suggestions please for a quick fix, either in storyline or with code?
4 Replies
A javascript developer would probably be a better place for your jquery/javascript question. For example, stackexchange. Your loader logic is the root of the jitter
Hi Tim!
We have a previous E-Learning Challenge that included image sliders. Perhaps you can find some inspiration and ideas here.
Thanks for the pointers :)
I have come across this which can be embedded into a web object. it preloads the images nicely. I just need to find a preloader script now to show a spinner while the preloader works. http://spritespin.ginie.eu/
This discussion is closed. You can start a new discussion or contact Articulate Support.