dynamic-locale doesn't change language

Hi, I have dynamic-locale plugin and flags shows in footer. Gettext() is enabled, have verified that in phpinfo(). I use zpmobile theme. There are no console errors.

If I f.ex. click on German flag, I am taken to mysite.com?locale=de_DE. Only the title of the photo album are affected, which I changed in admin.

But the menu is unchanged. It still sais "Gallery". It still sais "Archive", "Gallery Index", "Latest images", "prev", "next", etc.


  • fretzl Administrator, Developer
    Sure your cache is not playing tricks?
    I always have to refresh the page after switching languages.
  • acrylian Administrator, Developer
    Are you sure you have the German locale on your server? IF you haven't it will not work as the gettext functionality is dependend on that. The titles itself are not using gettext which is why they work.
  • @fretzl: You mean the user should clear his cache after switching language? that isn't very explicit. No one would guess unless they are techs or they know. Anyway, I tried clearing browser cache, and also Purge HTML cache+Purge Image cache+Purge RSS cache in admin, but no diff.

    @acrylian: I dont know what that means, how do I check if I have "German locale" on my server? Does phpinfo tell? Server host is A Small Orange.
  • acrylian Administrator, Developer
    To answer for Fretzl quickly. He primarily refers to for example browser caches which sometimes are a bit too persistent and show an older version of the site. Sometimes it takes one or more page reloads.

    But I am sure in your case it is the locale missing. I don't know your host but if it is no German host it most likely has only its own locale being English. You can install this plugin to list all available locales:

    But easier is probably to just ask your host and if they can install it for.
  • Webfaction said all languages (incl. German) have already been installed. I don't know what specific to ask for.
  • acrylian Administrator, Developer
    Then try the list_locale file I linked above to show if that is really the case. There should be a de_DE listed.

    Also best review your error logs, just in case.

    Additionally make sure you didn't set the language settings (Options > General) to "HTTP_Accept_Language" as then the browser default maybe overrides the choice.
  • In Language settings I have enabled about 5 different languages. HTTP_Accept_Language is disabled there.

    list_locales does not show these five languages under Http Accept Languages, but they are listed under Supported locales.
  • wait
  • It seems I have a cache problem. Change language works fine with private/incognito window. Clicking Purge HTML cache and then refresh after changing language doesn't help if not in incognito/private window.
Sign In or Register to comment.