Thursday, March 1, 2012

Re: [Rails] Re: how to use link_to with :remote=>true in rails 3.2.1

On Mar 1, 2012, at 2:09 AM, Manish Nautiyal wrote:

> after doing some googling I got the answer
>
> wrong way :
> $("#allclick").update("<%= escape_javascript(render(:partial =>
> "goclick")) %>");
>
> ====================================================================
> correct way :
> $("#allclick").html("<%= escape_javascript(render(:partial =>
> "goclick")) %>");
>
> ====================================================================
> Instead of update now I'm using html
>

Update would work perfectly if you were using Prototype.js instead of jQuery.

Walter

--
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@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate