The result of your cycle will be a string, so the normal way to use
this would be to assign the string to a class name,
and then for each class, you define the background style you need in
your stylesheet.
<tr class="<%= cycle("even", "odd")
-%>">
see
http://www.railsbrain.com/api/rails-2.0.2/doc/index.html?a=M001928&name=cycle.
If you want to build the whole style fro the cycle, it would need to
be like this
style="background-color: <%= cycle("#fff", "#ccc")
hth
Tonypm
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---