Hi, Friends, I am working on ruby on rails, 1) I have created a login form <div class="smallfont"> <%=flash[:notice].to_s%> <fieldset> <legend> Please Log In </legend> <% form_tag do %> <p> <label for="name">Name:</label><br/><br/><br/> <%= text_field_tag :name, params[:name]%> </p> <p> <label for="password">Password:</label><br/><br/> <%= password_field_tag :password, params[:password]%> </p> <p> <%= submit_tag "login"%> </p> <%end%> <%#= button_to "Back", :controller=>:main, :action=>:unreg_disp_data%> </fieldset> </div> 2) Then rendered this form in view using render_component but after rendering this way i was unable to get the passed arguments 3)If i am creating a link instead of render_component e.g. <%= link_to_remote "Sign In",{ :update=>"account",:url => {:controller => :account,:action => :login} }-%> it works fine Can anyone suggest a solution for this, I will be thankful for the same Regards, Kiran Polawar --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
> > 2) Then rendered this form in view using render_component but after > rendering this way i was unable to get the passed arguments >Is there any particular reason you are using render_component? render_component is mostly dead (IIRC it''s because components are big and heavy, because they are actually separate controller instances under the hood (which is probably why accessing params from the ''other'' instance of ActionController doesn''t work) Fred> 3)If i am creating a link instead of render_component e.g. > > <%= link_to_remote "Sign In",{ > :update=>"account",:url => {:controller => :account,:action > => :login} }-%> > > it works fine > > > Can anyone suggest a solution for this, I will be thankful for the > same > > Regards, > Kiran Polawar > > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Frederick Cheung wrote:>> >> > Is there any particular reason you are using render_component? > render_component is mostly dead .....why accessing params from the > ''other'' instance of ActionController doesn''t work) > > Fred(Note: this problem is earlier posted by "Pedro Cardoso" but there is no solution given.) Thanks for the help, But I think I require some solution for this problem,I have created a home page and for a/c management I have created some .rhtml files, at the home page I want to render the login form.Please give me some solution.. Kiran -- 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 -~----------~----~----~----~------~----~------~--~---
On 2 Oct 2007, at 10:20, Kiran Polawar wrote:> > Frederick Cheung wrote: >>> >>> >> Is there any particular reason you are using render_component? >> render_component is mostly dead .....why accessing params from the >> ''other'' instance of ActionController doesn''t work) >> >> Fred > > (Note: this problem is earlier posted by "Pedro Cardoso" but there is > no solution given.) > Thanks for the help, But I think I require some solution for this > problem,I have created a home page and for a/c management I have > created > some .rhtml files, at the home page I want to render the login > form.Please give me some solution.. >components are dead. don''t use components. I''ve never used components (because of the former) and so I''m not well aquaintent with their intricacies. You probably could get something together using the :locals option of render, but like I said, components are dead. Use a partial. Fred> Kiran > -- > 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 -~----------~----~----~----~------~----~------~--~---
Frederick Cheung wrote:> On 2 Oct 2007, at 10:20, Kiran Polawar wrote: >>> > components are dead. don''t use components. I''ve never used components > (because of the former) and so I''m not well aquaintent with their > intricacies. You probably could get something together using > the :locals option of render, but like I said, components are dead. > Use a partial. > > FredThank you very much..... :) it really works. I have used partials to do the same thing along with passing the arguments.... Kiran Polawar -- 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 -~----------~----~----~----~------~----~------~--~---
Kiran Polawar wrote:> Frederick Cheung wrote: >> On 2 Oct 2007, at 10:20, Kiran Polawar wrote: >> > >>> >> components are dead. don''t use components. I''ve never used components >> (because of the former) and so I''m not well aquaintent with their >> intricacies. You probably could get something together using >> the :locals option of render, but like I said, components are dead. >> Use a partial. >> >> Fred > >I have one more problem regarding using ajax, I want to show and hide div on mouseover and mouseout events of another div, but it doesn''t work, it continuously does same thing I am expecting some code or solution for it...... :) Have a nice time.... Fred -- 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 -~----------~----~----~----~------~----~------~--~---