ekallevig / jShowOff

A jQuery-based Features Rotator
http://ekallevig.com/jshowoff
85 stars 25 forks source link

Play once #8

Open dunny opened 14 years ago

dunny commented 14 years ago

First, jshowoff rules, and thank you for creating it!

Second, is there a way so that I can set it to only play once, ie stop on the last "slide"?

Thank you!

dunny

ekallevig commented 14 years ago

That would be a good feature to add, but it's not there now. You could probably tamper with the plugin a bit and get what you want. Try messing with the play() function and checking to see if the counter variable is equal to (or maybe 1 less than) the gallery.length value, then clear the timeout. I'll try to add that feature in at some point.

mowert commented 9 years ago

if((counter >= gallery.length) || (index >= gallery.length)) { counter = 0; var e2b = true; } replace if((counter >= gallery.length) || (index >= gallery.length)) { pause();}