Language redirect

Topics: Developer Forum
Oct 1, 2016 at 8:54 AM
I use N2 cms on a site with multiple languages. I have started to create pages that are translations of each other by linking them in the admin area. I use a geo ip service to detect which language the visitor comes uses. Right now this task is done in a LanguageIntersection controller. But I need to be able to do this on every page type. I get the language by geo ip and check if the current page has a translation in the requesred language. If I find a translated page I want to do a redirect to that page. My question is where I should put the geo ip code so it is executed for all page type when a page/content item is requested?