Harold A. Giménez Ch. wrote: > OK Great... > > You were calling the + method, which concatenates two string objects, on > a > User object. In your original code, the @login variable did not hold a > string object, but a user object (returned by the call to > User.find_by_login( ... ). > > Ruby was rightfully complaining that the + method was not defined on the > user object. @user.login returns a string, which does have the + method > and > therefore you can concatenate with the rest of your string (in the flash > message). > > > > On Mon, Mar 9, 2009 at 7:59 PM, Chris Gunnels <
oooo ok in PHP (what im used to programming), I was assigning @login = User.find_by_login(params[:l]) which would, in php, tell php the @login is a string and not an object. I have to get used to everything being an object in ruby. -- 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@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---