I’ve added Url Rewrite to server and can take out trailing slashes. I tried taking out “home” from the url but I get a redirect loop because of the umbracoHideTopLevelNodeFromPath setting and redirect.
I am route Hijacking. The WebRoot Controller is not called with the above config.
I am using Models.Builder in VS.
Here is the Index Action of the Home Controller:
public override ActionResult Index(RenderModel umbracoModel)
{
var model = new Home(umbracoModel.Content);
return CurrentTemplate(model);
}
What do I do?
Note – I need the flexibility to scale BR, CA, etc. into multiple languages in the future…
Okay, so there are a couple of things you can do, but first, you said that you've added a URL rewrite to remove the trailing slashes. There is a setting in UmbracoSettings.config that determines if the trailing / should be added which can be found here.
With regards to getting rid of the home URL, if you add a content picker property to your WebRoot node for each language, and make sure it has the alias: umbracoInternalRedirectId it will perform an internal redirect so the URL without home will load the home node. More info
How to get rid of “home” in the url? (Mydomain.com/home/)
How to get rid of “home” in the url? (Mydomain.com/home/)
Architecture: (All [WebRoot] types are redirected to the first [Home] type.) v7.6.3
Web.config settings:
I’ve added Url Rewrite to server and can take out trailing slashes. I tried taking out “home” from the url but I get a redirect loop because of the umbracoHideTopLevelNodeFromPath setting and redirect. I am route Hijacking. The WebRoot Controller is not called with the above config. I am using Models.Builder in VS. Here is the Index Action of the Home Controller:
What do I do?
Note – I need the flexibility to scale BR, CA, etc. into multiple languages in the future…
Hi Brett,
Okay, so there are a couple of things you can do, but first, you said that you've added a URL rewrite to remove the trailing slashes. There is a setting in UmbracoSettings.config that determines if the trailing / should be added which can be found here.
With regards to getting rid of the home URL, if you add a content picker property to your WebRoot node for each language, and make sure it has the alias:
umbracoInternalRedirectId
it will perform an internal redirect so the URL without home will load the home node. More infoHopefully that helps ?
Nik
is working on a reply...