Page navigation using named routes (need your help)


I want to use named routes to create page navigation.
For instance I have these named routes:

map.homepage ‘/’, …
map.links ‘/links’, …
map.catalog ‘/products/catalog/’, …
map.catalog2 ‘/catalog/:year/’, …

And then have a map which defines navigation on the basis of the named
routes (just for imagination):

homepage: mysite > homepage
links: mysite > links
catalog, catalog2: mysite > products > catalog

My problem:

The only thing I need to know is the name of the current route, which
been distinguished from the current request. Can you help me, please?
Where can I get the name?

Thank you,

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs