I would like to add a visual effect to one of my web pages and in the stage where I don’t know what I don’t know. I’ve talked to my buddy Google about this and (s)he has pointed me at a number of different web pages that all seem to have 2006 dates on them. I can try looking at them more carefully (and will keep looking), but I thought I would toss my question out to you folks in the mean time.
I would like to display (in my #index view) a table of some data. Most (if not all) of the rows have other data associated with them. I would like to display a plus sign next to each row which, when clicked by the user, would expand the view to include the associated data – sort of like the way Gmail can expand and collapse “conversations”.
Can anybody point me at a recent tutorial that might get me started down this path?
Rails problem/question at all.
I’ll head down that path. Thanks.
There are different paths you can take. Prototype/Scriptaculous is
(currently) incorporated into the framework, so that can be an easy
place to start (particularly when using rjs to deal with controller-
type actions in your controllers).
frameworks). These may behave differently, and have benefits or
weaknesses when compared with Prototype.
The API documentation for the frameworks themselves are really helpful
places to start. For using them with Rails, railscasts.com is a
fantastic place to get pointers (search for 'rjs', 'prototype' or
you will simply need to create a div with the data in a hidden row
This is actually so simple that it not worth encapsulating this in
Check this link:
If you have the time get a copy of the book Ajax on Rails (O'Reilly).