A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More.
AI OnAI Off
A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More.
I'v defined the following in my web.config
<siteHosts>
<add name="site.com.local" language="en" />
<add name="site.se.local" language="sv" />
<add name="*" />
</siteHosts>
works like a charm.
Now, if I want to change language when surfing around on one site to the other, can I in a easy way change the host defined in siteHosts aswell?
Today i use the following:
return string.Format(@"<a href=""{0}"" class=""{1}"">{2}</a>", EPiServer.UriSupport.AddLanguageSelection(pd.LinkURL, pd.LanguageID), pd.LanguageBranch, Translate("/lang/" + pd.LanguageBranch));
I guess I can use EPiServer.Configuration.SiteElement to obtain the siteHost, but is there a method that can do this automagically?