How to duplicate the names in the url bar. For example i am having products controller and index method. Now in my project i am running like localhost:89733/Products/Index. But instead of Products/Index what want to give another name to run the same action method. How can i do that. I mean i don’t want to leak my controllers information to others. Any help is appreciated.
How to duplicate the names in the url bar. For example i am having
Share
You could configure a custom route:
Now when you navigate to
mycustomproductsname/123, theIndexaction of theProductscontroller will be executed and passed 123 asidparameter.