Hi!.
Is there a way to call to another controller with link_to_remote?
Something like this:
<%= link_to_remote "Tests", {
:controller => "tests",
:action => "tester"
}
%>
Salu2...
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---
explain better.. you can specify the controller you want on :controller => ''something'' or do you want to call two controllers? masch wrote:> Hi!. > Is there a way to call to another controller with link_to_remote? > Something like this: > <%= link_to_remote "Tests", { > :controller => "tests", > :action => "tester" > } > %> > > Salu2...-- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Right, i used :controller => "Tests", but it doesn''t work.
The html result is :
<a href="#" onclick="new
Ajax.Request(''/test/tester'',----
is it right?
Because it never call to tests controller.
Salu2...
On Feb 1, 2008 9:00 AM, Andreh Luis
<rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org>
wrote:>
> explain better..
>
> you can specify the controller you want on :controller =>
''something''
> or do you want to call two controllers?
>
>
> masch wrote:
> > Hi!.
> > Is there a way to call to another controller with link_to_remote?
> > Something like this:
> > <%= link_to_remote "Tests", {
> > :controller => "tests",
> > :action => "tester"
> > }
> > %>
> >
> > Salu2...
>
> --
> Posted via http://www.ruby-forum.com/.
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---
how do you know your controller never gets called? what do you have on the ''tester'' action on the tests_controller.rb? when you use link_to_remote you make a ajax call, is this what you want? masch wrote:> Right, i used :controller => "Tests", but it doesn''t work. The html > result is : > <a href="#" onclick="new Ajax.Request(''/test/tester'',---- > is it right? > Because it never call to tests controller. > > > Salu2...-- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Sorry...watching code to explain the problem i realize that the real controller name was test and not testS.. Thanks you Some much for you help!!!!..:D Salul2... On Feb 1, 2008 4:10 PM, Andreh Luis <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> > how do you know your controller never gets called? > > what do you have on the ''tester'' action on the tests_controller.rb? > > when you use link_to_remote you make a ajax call, is this what you want? > > masch wrote: > > Right, i used :controller => "Tests", but it doesn''t work. The html > > result is : > > <a href="#" onclick="new Ajax.Request(''/test/tester'',---- > > is it right? > > Because it never call to tests controller. > > > > > > Salu2... > > -- > > Posted via http://www.ruby-forum.com/. > > > >--~--~---------~--~----~------------~-------~--~----~ 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-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---