So I know about remote_form_for, and I've messed around with RJS a little bit. They work well for simple stuff. But if I'm looking to do anything beyond really basic CRUD operations, it seems somewhat lacking.
Let's say I've got an unordered list of items of some sort, with a remote_form_for an item; when the form is submitted, the item is inserted into the database and a new list item is appended to the bottom of the list. That's all easy. But what if I want to do something to the form after the Ajax request returns, like clearing out and then focusing on a text field? While prototype has Form.Element#focus and #clear methods, I can't find Rails hooks into those methods mentioned in any documentation. How do you guys handle those sorts of more complicated interactions? Are there RJS methods for this kind of stuff that I'm just missing? (It is really tough to find anything recent on Google about RJS--has it fallen out of favor?) Or do you just hand-code the Javascript stuff separately? That's what I've ended up doing for now--which has the additional benefit of not resorting to nasty per-element "onclick" attributes. Any help or pointers in the right direction are appreciated! :Dan --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Heroku" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/heroku?hl=en -~----------~----~----~----~------~----~------~--~---
