Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4556190
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T17:19:52+00:00 2026-05-21T17:19:52+00:00

I have been following a tutorial @ Noupe with the intention of learning Rails.

  • 0

I have been following a tutorial @ Noupe with the intention of learning Rails. It’s going well and the app works, but I gather it was written for Rails 2, so there are some deprecated pieces of code used.

While I have resolved most of these, I have one remaining problem with the routing. The Rails 2 code in the tutorial is:

ActionController::Routing::Routes.draw do |map|
map.resources :posts
map.connect ':controller/:action/:id'
map.connect ':controller/:action/:id.:format'
end

This works fine, but it is the old code. I have attempted to rewrite the code as follows:

Twitter::Application.routes do
resources :posts
match ':controller/:action/:id'
match ':controller/:action/:id.:format'
end

This results in an error when I attempt to visit http://localhost:3000/posts –

Routing Error
No route matches “/posts”

Can anyone suggest where I am going wrong? I did notice that I get a compiler error if I write twitter in the first line (instead of Twitter) – since my app is named twitter, I thought this might be the issue, but it does not seem to be.

Any help greatly appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T17:19:53+00:00Added an answer on May 21, 2026 at 5:19 pm

    It seems like you are missing the call to the method draw. Try to change the first line to the following:

    Twitter::Application.routes.draw do
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm a newcomer to Rails, and have been following the tutorial on the rails
Have been following Rails Tutorial by Michael Hart rails version 3.0 on mac OS
I have been following this tutorial and everything was going nice and easy until
I have been following a tutorial on creating an iPhone app with multiple xibs.
I am in the process of learning cocos2d-android. I have been following a tutorial
I have been following a tutorial to make Android App Widgets, and I was
I have been following an opengl tutorial, but for some reason when i added
I'm doing the Rails tutorial, and have been following it fairly strictly. However, my
i have been following apps snowfall tutorial, but i am getting some issue in
I have been following the tutorial to install Ruby on Rails on the mac

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.