With the move to Google groups, is the spinoffs list now going to get all Ruby stuff or was this just a case of mistaken list identity?

On 8/22/06, Jarkko Laine <[EMAIL PROTECTED]> wrote:

On 22.8.2006 , at 14.27, Eduardo Yáñez Parareda wrote:

>
> Although link_to_remote works fine, I don't understand (I've already
> read the documentation you told
> me) why link_to doesn't work. Which is the difference usinf link_to or
> link_to_remote?

The former creates a normal, old-fashioned link:
             <a href="">
The latter creates an Ajax'ed link, clicking of which will trigger an
XmlHttpRequest call:
             <a href="" id="flag_link_6" >Ajax.Request('/flags/create/6', {asynchronous:true,
evalScripts:true}); return false;" title="Flag this content as
inappropriate.">Flag</a>

>
> link_to does: call to the controller, then executes action, then
> search
> for a view (.rhtml, .rjs) with
> the same name of the action. Does not link_to_remote do the same
> thing?

Neither of them do that. They are just helpers that produce html (see
above). One creates a normal link, the other an Ajax link.

You can only use RJS templates for Ajax stuff, so link_to_remote is
what you're looking for.

//jarkko

>
>
> >

--
Jarkko Laine
http://jlaine.net
http://odesign.fi



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" 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/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---

Reply via email to