$.fn.play = function(){var options = $.extend($.fn.qslider.defaultsSetting,$.fn.qslider.options);$('.qS-scene').each(function(index){ $('img', this).delay(options.sceneDuration*index+options.scenePause).each(function(index){ $(this).delay(options.itemDelay*index).each($.fn.moveIn) })}) }
xfunction yourFunction() {// content of yourFunctionsetTimeout("yourFunction()", speed);}yourFunction();
I could make a separate function if it helps, if you want to see it in action (i'm not good @ describing) go here:
Here's some more reading on it: http://wallofscribbles.com/2011/setinterval-the-sneaky-basterd-child-of-javascript/