cancel
Showing results for 
Search instead for 
Did you mean: 

Remove Language Detection (5.0d)

chrati
Champ on-the-rise
Champ on-the-rise
Hello,

I have just installed Alfresco 5d CE on Ubuntu 15.04 running with Nginx 1.6.
For this installation I would like to turn off the browser language detection and only keep EN as the default language.

For this I went to lots of articles:
https://forums.alfresco.com/forum/developer-discussions/language-packs/changing-default-language-040...
http://stackoverflow.com/questions/15872540/how-to-force-alfresco-share-use-only-one-language-indepe...
https://forums.alfresco.com/forum/installation-upgrades-configuration-integration/configuration/solv...

In the end I tried updating startup.sh with:
export JAVA_OPTS="${JAVA_OPTS} -Duser.country=US -Duser.region=US -Duser.language=en"

But this or all other options weren't working for me.
I sthere anything different in version 5?

Thanks in advance
Chris
1 REPLY 1

chrati
Champ on-the-rise
Champ on-the-rise
Hello,

I solved this issue now by compiling nginx with the AcceptLanguageModule.

I used the following conf for it:


server {

if ($host ~* ^(en\.*|www\.en\.*)) {
        set $language 'en-EN';
        set $http_accept_language 'en-EN';
}
add_header Accept-Language $language;



location / {

        root            /opt/alfresco-5.0.d/tomcat/webapps/share/;

        proxy_pass      https://localhost:8443;
        proxy_set_header        X-Real-IP               $remote_addr;
        proxy_set_header        X-Forwarded-For         $proxy_add_x_forwarded_for;
        proxy_set_header        host                    $host;
        proxy_set_header        X-Forwarded-Server      $host;

        proxy_set_header        Accept-Language $language;
}
}


Best
Chris