How to clear php's gettext cache without restart Apache nor change domain?

前端 未结 6 1540
别跟我提以往
别跟我提以往 2020-12-03 07:34

This is a little code snippet from php manual:

putenv(\'LC_ALL=zh_CN\');
setlocale(LC_ALL, \'zh_CN\');

bindtextdomain(\'domain\', \'./locale\');
textdomain(         


        
6条回答
  •  鱼传尺愫
    2020-12-03 07:37

    I called clearstatcache(); function after translating from messages.po to messages.mo and its working fine without restarting apache. Loading each change what I am making in any language file.

提交回复
热议问题