[jQuery] Re: How to use one button to toggle multiple panels in succession

2009-01-29 Thread Stephan Veigl
That depends on what you want to happen with the hidden divs. Suppose you have added a - to every ".myPanel" div. 1- Scenario 1: hidden divs stay hidden and the next unopened div is shown var myPanels = $(".myPanel").hide(); var nextPanel = 0; $(".myHeader button").click(function(){ i

[jQuery] Re: How to use one button to toggle multiple panels in succession

2009-01-28 Thread Kevin Rodenhofer
Not bad at all...if I "remove" them with slideUp, in succession, how would I do that? On Wed, Jan 28, 2009 at 7:39 AM, Stephan Veigl wrote: > > I'm not sure if I realy understand what you want to do, but it could > look something like > > HTML: > >+ >1 >2 >3 >4 >5 > > >

[jQuery] Re: How to use one button to toggle multiple panels in succession

2009-01-28 Thread Stephan Veigl
I'm not sure if I realy understand what you want to do, but it could look something like HTML: + 1 2 3 4 5 JavaScript: var myPanels = $(".myPanel").hide(); var nextPanel = 0; $(".myHeader button").click(function(){ if (nextPanel < myPanels.length) { $(