[Rails] routes.rb and configuration over convention

2012-03-14 Thread tydeas
Hello there, I am new to the rails framework. I have seen that rails uses the Convention over configuration philosophy. Then when I create a controller post_controller I have to actually configure it in the routes.rb file to get it working. Is this the other way around, configuration over

Re: [Rails] routes.rb and configuration over convention

2012-03-14 Thread Peter Vandenabeele
On Wed, Mar 14, 2012 at 10:28 AM, tydeas tydeas...@gmail.com wrote: Hello there, I am new to the rails framework. I have seen that rails uses the Convention over configuration philosophy. Then when I create a controller post_controller I have to actually configure it in the routes.rb file to

[Rails] Routes.rb

2010-08-17 Thread Hemant Bhargava
Hello All, In routes.rb, to create and access a new page everytime i need to write :page_name = :any to my config/routes.rb. Can you guys tell me any better alternative to this? Thanks in advance. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are

Re: [Rails] Routes.rb

2010-08-17 Thread Jim Croft
On 17 Aug 2010, at 11:00, Hemant Bhargava wrote: In routes.rb, to create and access a new page everytime i need to write :page_name = :any to my config/routes.rb. Can you guys tell me any better alternative to this? I'm not 100% sure I understoon what you're after but take a look at:

[Rails] routes.rb

2010-08-13 Thread Abder-Rahman Ali
I'm following the tutorial here: http://edgeguides.rubyonrails.org/getting_started.html And, so far, I have the following in the routes.rb file: get home/index resources :posts root :to = home#index I know what root :to = home#index is. But, what is the use of the following, what do they mean?

[Rails] routes.rb -- is it really needed?

2009-07-01 Thread mbiker
Has anyone recently thought about just merging routing into the controller? ActiveRecord handles associations very well. It seems like the controller should be able to handle its own associations just as well. Andy --~--~-~--~~~---~--~~ You received this message

[Rails] routes.rb noob question...

2009-04-06 Thread internetchris
Hey Everyone, I'm wondering if the statement below are redundant? Once you define the resources for a particular controller, that should be it right? I'm assuming all I need is the second statement below. map.resources :customers map.resources :customers, :has_many = :accounts Thanks! Chris

[Rails] routes.rb problem

2009-03-06 Thread Salil Gaikwad
I am having problem with routes.rb I want to access same page using two different url's for that i had done following in routes.rb 1] map.connect 'projects/:project_id/issues/:action', :controller = 'issues' so when my url is http://localhost:3000/projects/xyz/issues/new i access the

[Rails] routes.rb ... killing the apps ??

2009-03-03 Thread Simone R.
1) create a RoR project on Netbean 2)generate scaffoldcar name:string power:string 3) db:create 4:)db:migrate 5) Run project now on http://localhost:3000/cars you can find the app and play a little , the app is WORKING and SAVE every car you create 6)generate scaffold animal

[Rails] routes.rb question

2009-01-08 Thread Richard Schneeman
I'm trying to go to localhost/phrases/new where 'phrases' is my controller and 'new' is my action which will simply show my new.html.erb In my routes i have: map.connect '/:controller/:action' Yet every time i go to phrases/new, I get redirected to my show action http://pastie.org/356249 I

[Rails] routes.rb

2008-12-15 Thread Mark Moore
Hi, I am going through a tutorial in a rails book. I have Something off with routes: I have RESTful resource in routes.rb: ... map.resources :users, :member = { :enable = :put } do |users| users.resources :roles end ... and in a html.erb partial I have: ... %= link_to 'assign role',