jQuery cycle plugin with different timeout values for each slide -


I am trying to cycle through various cycles of cycle using the jQuery cycle plugin. Based on the length of the quote I would like to display quotation marks for different times. To get this, I get the content management system to output the second volume as if the name of class 13 such as fear 13 will be for 13 seconds.

This is my non-trying effort:

  $ ('.feed feeds'). Cycle ({cycleTimeout: 10, after: onCycleAfter}); CycleAfter () {$ ('.feed feature') on function Cycle ('break'); Var period = $ (this) .attr ('class'). Substring ($ (this) .attr ('class') IndexOf ('dur') + 3) setTimeout (oncycleEnd, duration * 1000); } Function oncycleEnd () {$ ('.featured feed'). Cycle ('resume'); }  

Is this possible with the cycle? If there is another plugin that will work? I really do not need fancy effect, just enough fade in the fade-out will be enough.

Many thanks

You can use, like:

  $ ('.feed feeds'). Cycle ({timeoutFn: function (currElement, nextElement, opts, isForward) {var term = $ (currElement) .attr ('class') Substring ($ (currElement) .attr ('class') Indexoff ('Door' ) + 3) return period * 1000;}});  

However, you can use it instead of a category, something like this:

  & lt; Img data-period = "2000" src = ". .." />  

Then your code is a bit simpler:

  $ ('feature feed'). Cycle ({timeoutFn: function (currElement, nextElement, opts, IsForward) {return parseInt ($ (currElement) .attr ('data-period'), 10);}});  

Comments