Hi All,
i like to do a multilanguage-multiregion-site, but i have no clue how i can do the routing.
as an example i like to have three languages in kirby via the basic multilanguage setup: en, de, fr
only these language-sites are available to edit via panel/texteditor, but i also need an indicator for the region of the user. this should be done via an select-field for language and country, which links to an url with the lang-region-code.
default lang should be ‘en’ with no lang-region-slug.
if no region is selected, only the language-code should route to the desired page.
if a region is available, this should be stored in a session/cookie and the page-template have to be able to react to that in some way.
so the resulting urls can be something like this:
mydomain.com/ -> home
mydomain.com/about -> about
mydomain.com/about/team -> about/team
mydomain.com/en/ -> home
mydomain.com/en/about -> about
mydomain.com/en/about/team -> about/team
mydomain.com/en-us/ -> home
mydomain.com/en-us/about -> about
mydomain.com/en-us/about/team -> about/team
mydomain.com/de -> start
mydomain.com/de/ueber-uns -> ueber-uns
mydomain.com/de/ueber-uns/team -> ueber-uns/team
mydomain.com/de-de -> start
mydomain.com/de-de/ueber-uns -> ueber-uns
mydomain.com/de-de/ueber-uns/team -> ueber-uns/team
mydomain.com/de-ch -> start
mydomain.com/de-ch/ueber-uns -> ueber-uns
mydomain.com/fr-fr -> maison
mydomain.com/fr-fr/sur -> sur
mydomain.com/fr-fr/sur/equipe -> sur/equipe
mydomain.com/fr-ch -> maison
mydomain.com/fr-ch/sur -> sur
mydomain.com/fr-ch/sur/equipe -> sur/equipe
#1 how to route ‘lang-region-codes’ to ‘lang-pages’? also with the default uri?
#2 how to save the region to a session or cookie, so the template can react in some way?
#3 how to auto-redirect on first visit to lang-region?
If someone is experienced with that, it would be really nice to get some help or hints.
Tnx!