Hello,
I am currently updating my website in Hugo 0.26 and making it multilingual.
I am using :
defaultContentLanguage = "en"
defaultContentLanguageInSubdir = true
And i wanted to know:
Does hugo redirect any link made to the BaseDir to the default language when used with the defaultContentLanguageInSubdir
option ?
Like redirecting someone accessing www.example.com
to www.example.com/en/
without to configure the server ?
Thanks.
It does not. You will only see the root domain and usual url’s when accessing the default language.
For example, this is my site and the default is also EN: https://brunoamaral.eu/
The alternative portuguese version is at https://brunoamaral.eu/pt/
Okay, thanks you.
I will make the redirection in Netlify.
But if only using the languages in subdir, i think it should redirect at least the homepage from the root to the one in the default language the website in using.
EDIT: I see, after restarting the hugo server, than it is redirecting automatically. I do not know if this in the correct behavior, if this is hugo doing it or directly the browser.