I have used scaffold to create my rails project and hence I have a
database containing a table called “results” and when i call the “show”
action followed by the ID it brings up a list of the relative record and
What I want though is for if someone types in say
localhost/results/etab-mobile that it maps dynamically to
localhost/show/1 but keeps localhost/etab-mobile in the address bar. the
“etab-mobile” title is found in the database under “module_name” so can
be pulled out for use.
I know this can be done in the routes.rb folder statically but would
like to do it in the controller so that its not as static.
is this possible?