On Thu, Sep 3, 2009 at 11:14 AM, zambezi<[email protected]> wrote:
>
> Hello Rick and thanks for answering,
>
> I'm feeling rather muddled.  In my brief ROR history I've been working
> under the assumption that naming conventions called for controllers to
> be in the singular.  Of course I'm finding out that much has been
> deprecated.  So  would you please confirm that controller names are
> supposed to be plural.

This is a different Rick

Since Rails became Restful, it's more common to have plural controller
names since this is the default when generating routes using
map.resources (and even map.resource).
>
> Regarding �...@responder = Responder.new(params[:responder])
> Since models and tables are "routeless", I'm not clear why routing
> should be an issue here.  And I thought that if the params hash is
> empty, I will get an empty @responder object which is what I expect in
> this case.
>
> I appreciate any further help you can offer.

I think you've run into another unfortunately name clash.

I'm assuming that you have a model called Responder, unfortunately it
looks like in your controller in the line

   @responder = Responder.new(params[:responder])

Responder is actually resolving to ActionController::MimeResponds::Responder

You might try something like

@responder = ::Responder.new(params[:responder])

to force Ruby to look in the outermost namespace.


-- 
Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Twitter: http://twitter.com/RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale

--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to