You shouldn’t be using the index.html file in the public folder inside
application’s root directory. This is just something to display for when
have nothing at the beginning.
In your config/routes.rb I’m guessing you’ve defined something like:
map.connect ‘’, :controller => “welcome”
Because that is what’s commented out by default in the config/routes.rb
The error you’re getting is generated from Rails looking for a
file called “welcome_controller.rb” in app/controllers, the file is not
there and Rails throws a nice error. To generate the controller type
script/generate controller welcome.
As of Rails 2.0 controller names should be pluralized. This is extremely
helpful for when you get to “RESTful Routing” because typing out stuff
new_post_comment_path is much better than :controller => “comments”,
=> “new”, :post_id =>
depending on what kind of application you’re making, think of what the
object should be and pluralize the name, and type script/generate
<object’s pluralized name>. You will also need to generate a model for
object, and this name should be singular.
On Dec 11, 2007 10:21 AM, Mike [email protected] wrote:
“uninitialized constant WelcomeController”
What should I be doing differently?