Expand my Community achievements bar.

SOLVED

Persistent Language Preference and Single Display of Language Selector Popup per Visitor Level

Avatar

Level 1

We need a feature that remembers the language selected by a visitor from the Language Selector dropdown popup and this should be displayed per visitor level. When the visitor revisits the page, they should be redirected to their previously preferred language, both in the same browser on subsequent visits and across different browsers. Additionally, the Language Selector popup should only be displayed at visitor level, ensuring a seamless experience by remembering their preferred language and applying it automatically on future visits.

 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hello @sonaik1 

You can use Cookies/ Local storage to identify the language selected by a visitor and then a action to display language selector or redirect them to specific page.

 

All of this can be done by writing a custom code in an experience.


     Manoj
     Find me on LinkedIn

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

Hello @sonaik1 

You can use Cookies/ Local storage to identify the language selected by a visitor and then a action to display language selector or redirect them to specific page.

 

All of this can be done by writing a custom code in an experience.


     Manoj
     Find me on LinkedIn

Avatar

Level 1

Thanks @_Manoj_Kumar_ , yes this solution works.

However, we also tried with adobe.target.trackEvent and fetched this via profile script 

'${user.selectedLanguage}', which we wanted to achieve via Target's Visitor level component. Thanks for your response on this.

 

            // send param attaching pathSegment and fetching with profile script selectedLanguage
            adobe.target.trackEvent({
    "mbox": "target-global-mbox",
    "params": {
        "profile.selectedLanguage": pathSegment
    }
});
        });
    }