Skip to content
Advertisement

Is there a way to cycle through Bootstrap tabs automatically (similar to carousel)?

I would like the Bootstrap tabs to cycle through each tab, kind of like a carousel, changing every 10 seconds or so. I figure it’s going to require some custom javascript (but I’m a bit of a novice)!

(I’d also like the cycle to stop if a tab has been manually clicked, but that’s more of a ‘stretch goal’!)

Here’s what I’ve got so far: http://jsfiddle.net/59Lyhqmn/31/

I’ve tried implementing solutions from similar questions, such as:

JavaScript

but I’ve had no luck so far!

Any help would be much appreciated!

Advertisement

Answer

I saw your fiddle I came up with the solution using simple iteration JSFiddle Link Working

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement