Hi. I was wondering if anyone has a site with ruby tutorials split into topics based on the task you''re trying to perform? sort of like tutorials which you can follow to actually add functionality to an application? the areas I''m needing advice on are: 1. Passing data from forms and displaying on another page - I want to have the user enter their info on the users/new page, but instead of just clicking the ''Create'' button and it loads into the database, I want to show a confirmation page showing what they entered. 2. Maintaining sessions. E.g if a user logs in as themselves (matched to user.fname and user.lname in the user table), until such time as they click the logout button, that info must be stored somewhere, and based on that, if a user is logged in as x, display certain elements on the page, else, display something else. This relates to my post on including entire htm files in rhtml pages, if a user is logged in as a simple user, it''d include a certain navbar with options, if as admin, the bar would be different, giving other options. I would also want to use the login information to show bookings associated with that user. Also, how do I manipulate if and else statements in Ruby/Rails? So, if a user makes a booking, I want to match the from and to fields of that booking with the from and to fields of matching flights. So more DIY tutorials on each aspect of creating a project, rather than a programming guide. Thanks. -- 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 12/19/06, Hussein Patwa <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> > Hi. > > I was wondering if anyone has a site with ruby tutorials split into > topics based on the task you''re trying to perform? sort of like > tutorials which you can follow to actually add functionality to an > application?This information is more likely to be covered by books than online. The *Ruby* Cookbook had many practical examples for common ruby tasks (and some rails stuff). Theres a Rails cookbook too, if its in the same vein its likely to be what you are looking for (me too).> the areas I''m needing advice on are: > 1. Passing data from forms and displaying on another page - I want to > have the user enter their info on the users/new page, but instead of > just clicking the ''Create'' button and it loads into the database, I want > to show a confirmation page showing what they entered.In your Users controller create method enter something like this: redirect_to :action => ''confirm_details'' (basically put a confirm_details method in your controller and make a new view based on that method)> So more DIY tutorials on each aspect of creating a project, rather than > a programming guide.My experience is that in-depth Rails Tutorials/examples have to be paid for by purchasing the books that contain them. This isn''t a bad thing, but its a change when you are migrating from a corporate-sponsored framework like Java, .NET etc.where people are employed to write articles for free distribution. About the only negative is that the half life of Rails books is quite short. Agile Web Development With Rails is the killer Rails book to cut your teeth on, but its 2nd edition is only just out, and the 1st ed is very out of date now (<2 years old). Rails Recipes has some excellent stuff in there, but I am not at the level of proficiency yet where I can use many of those recipes (but they are great stuff, I know I am going to need a lot of them). Richard. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---