Hey there, i have have been able to build a login controller on my groups model and it works ( used the ruby cookbook example ) . Now that its working, i want to put it in a side bar that will be there through out the application. If the user is logged in , it will say so and have a logout link or button, if not, the login and password form will be there. Ok, i know how to do most of this, but i do not know how to mix views together. I have a login.rhtml, a logout.rhtml, and process_login.rhtml. The only one i use is the login.rhtml because the controllers just redirect around. Now, what i don''t know how to do is add my login or logout to the main application view so it will stay. Anyone know a good pointer, how-to, or tutorial for this? thanks --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
1) Look into partial templates. 2) Read about components (and why you should avoid them) 3) Look into using helpers. I posted some stuff on helpers/components on my blog: http://www.igvita.com/blog/2006/09/17/helpers-instead-of-components/ It may be of help.. Cheers, Ilya -- 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 Nov 9, 11:14 am, Ilya Grigorik <rails-mailing-l...-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> 1) Look into partial templates. > 2) Read about components (and why you should avoid them) > 3) Look into using helpers. > > I posted some stuff on helpers/components on my blog:http://www.igvita.com/blog/2006/09/17/helpers-instead-of-components/ > > It may be of help.. > > Cheers, > Ilya > > -- > Posted viahttp://www.ruby-forum.com/.Hey thanks for that link to your blog. i like your example too. Thats kinda what I want to do. I need the side bar, but also some links to other stuff. thanks again. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---