I''m not getting any love grouping controllers into separate namespaces and I''m hoping someone can tell me what I''m not getting: $ rails foo $ cd foo $ script/generate controller Namespace::Bar index $ script/server $ lynx http://localhost:3000/namespace/bar -> 404 -> Routing Error -> Recognition failed for "/namespace/bar" Many thanks in advance. -- Posted via http://www.ruby-forum.com/.
Hello Erik,> I''m not getting any love grouping controllers into separate > namespaces and I''m hoping someone can tell me what > I''m not getting: > > $ rails foo > $ cd foo > $ script/generate controller Namespace::Bar index > $ script/server > > $ lynx http://localhost:3000/namespace/bar > -> 404 > -> Routing Error > -> Recognition failed for "/namespace/bar"Can you show us what does your config/routes.rb look like ? -- Jean-Fran?ois. -- ? la renverse.
> > Can you show us what does your config/routes.rb look > like ? >That would definitely help, but I had something similar so you can give this a try. In config/routes.rb: map.connect '':controller/:action'' map.connect '':controller/:action/:id'' -- Andrew Stone -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060726/b73906be/attachment.html
Jean-Fran?ois wrote:> Hello Erik, >> -> 404 >> -> Routing Error >> -> Recognition failed for "/namespace/bar" > > Can you show us what does your config/routes.rb look > like ? > > -- Jean-Fran?ois.It''s stock as generated in the example. I have changed my routes.rb to specify the namespace and that works, I just thought it was free. I added this above the default route: map.connect ''namespace/bar/:action/:id'' :controller => ''namespace/bar'' and it works. Thanks. -- Posted via http://www.ruby-forum.com/.