1
I have a website and when entering the home page it is redirected to another view
.
Thus:
www.exemplo.com redirects to www.exemplo.com/Home/Hotsite
That’s because I have a feature that when entering the view
Home/Index www.exemplo.com/xpto
, will carry the view Index
which is the login screen, customized according to the parameter passed(foo) .
I wonder if it is possible to hide the redirected URL from view
Hotsite, so when I come in www.exemplo.com
, will display only www.exemplo.com
, and not www.exemplo.com/Home/Hotsite
.
It is possible to do this without changing the views
?
these are the routes I have:
routes.MapRoute(
name: "Inicial",
url: "{id}",
defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
);
routes.MapRoute(
name: "Default",
url: "{controller}/{action}/{id}",
defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
);
What version of Asp.Net MVC are you using?
– Randrade
Has, but, I need to see your route file and also if there is any route configured to site base, could post?
– novic
The version is Asp.net 4
– Gabriel Santos Reis
I put the routes I have configured
– Gabriel Santos Reis