IF this is my url http://localhost:55070/Server/1-Server
A link in that page will became
http://localhost:55070/Server/2-Instance_12
If I change the URL like this http://localhost:55070/Server/1-Server/
the link will be like this .http://localhost:55070/Server/1-Server/1-Instance_11
I want seconde type (http://localhost:55070/Server/1-Server/1-Instance_11/) always. If the user enters the URL like this http://localhost:55070/Server/1-Server it may cause some issues.
If this is the URL http://localhost:55070/Server/1-Server how can I append / to this http://localhost:55070/Server/1-Server/. So the links in next views are also append to it.
It is possible for user to remove the ‘/’ and then also i need to add ‘/’.
This is the Razor for creating the URL.
You could adapt this solution Lower case URLs in ASP.NET MVC to redirect the user when the url does not end with a /
Or put it in a HttpModule like so: