apache only works with gettext (localization) sometimes

One some restarts of my apache 2.2 webserver, it fails to "load"/bind my textdomains in php5 for localization of my websites.

For example, https://www.wineclubsouthafrica.co.uk/?mp=109 have a login-box to the upper right. Right now the text is in Swedish ("Inget konto än? Skapa konto här!") but after a few apache-restarts it's correctly localized into "No account yet? Create an account here!".

NOTE. I do not change any php-code, tags, config, .po/.mo-files or anything. The only thing that changes is the apache restarting.

Another note, if I get apache displaying my i18n/localization correct, the next day it fails to localize the same text again. Without a restart.

I am extremely confused. Any help is much appriciated!
mgabAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

NopiusCommented:
> NOTE. I do not change any php-code, tags, config, .po/.mo-files or anything. The only thing that changes is the apache restarting.

Hello. I suggest you have systemwide sweden locale. When you connect to the system from any 'ssh' client it propagates your locale, not server's, so you are getting correct 'English' locale after connection and apache restart.

> Another note, if I get apache displaying my i18n/localization correct, the next day it fails to localize the same text again. Without a restart.

If you are on Linux, your apache is restarted once a day to rotate logs, so it's locale reverts back to system wide.

How to change system wide locale on Debian: http://gallery.menalto.com/wiki/Debian_locale_HowTo

You need to restart _server_ after changing default locale...
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mgabAuthor Commented:
Will try it out but I am sure you're on the right track here!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
PHP

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.