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

  • SEARCH
  • Home
  • 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 7749523
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T11:04:11+00:00 2026-06-01T11:04:11+00:00

I got a resource called posts, now i want to map root to posts

  • 0

I got a resource called posts, now i want to map root to posts as a resource.
so as the result:

‘/posts’ => nothing

‘/posts/1’ => nothing

but

‘/’ => posts#index

‘/1’ => posts#show

  • 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-06-01T11:04:12+00:00Added an answer on June 1, 2026 at 11:04 am

    In config/routes.rb change

    resources :posts
    

    to:

    resources :posts, :path => '/'
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a RESTful resource (let's say posts ) that excludes the index action.
I've got a class that manages a shared resource. Now, since access to the
I've got a queue resource that is shared across multiple producers and multiple consumers.
Got a requirement to rebuild mssql full-text index. Problem is - I need to
I've got a model called ImplicitTest . It's called this as having a Ruby
Application-Stack: Rails3, CanCan, Devise, Shoulda I've got some nested Resources and want to test
I've got this class, let's call it Refund (because that's what it's called). I
There is Java tool (it is called Mallet) http://mallet.cs.umass.edu/download.php which I want to use
In my resource model I've got a subscription resource. It goes through lifecycle states
lately I got a bit confused concerning class-pathes in Manifest.mf-files. So what I want

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.