Hi, I’m pretty sure this is a simple problem but I can’t seem to work it
I have a series of news stories and I would like the body of the story
to be displayed (using a visual_effect toggle) when the user clicks on
The toggle works ok, but it does not matter which title I click on, only
the first story is ever displayed.
Can anyone see what is the problem?
Latest News<% for newsitem in @newsitems %>
<%= link_to newsitem.title, "#", :onclick => visual_effect(:toggle_appear, ('newsitem.id'), :duration => 0.5) %>
<%= newsitem.created_at.strftime('%a %d %b %Y, %I:%M%p') %> by <%= newsitem.user.login %>
<%= newsitem.body %>