Can I reset the cycle helper?

Hi:

I have lines in a table I wish to stripe BUT, every now and then
there is another type of line, a section header line. I’d like to be
able to start the line after a section heading always as one of the
two classes the cycle helper is cycling between. Is it possible? If
so, how?

bruce

PS. I realise I could do this with ‘odd_or_even’ or the %2 method
(mod function), but I do love the cycle helper - it is terse without
being unintelligible :slight_smile:

I have lines in a table I wish to stripe BUT, every now and then
there is another type of line, a section header line. I’d like to be
able to start the line after a section heading always as one of the
two classes the cycle helper is cycling between. Is it possible? If
so, how?

reset_cycle
http://api.rubyonrails.com/classes/ActionView/Helpers/TextHelper.html#M000431

As long you always want to start again with the first item, that should
work for you.