Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/247.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/clojure/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
PHP gettext方法给出空响应_Php_Gettext_Zend Server - Fatal编程技术网

PHP gettext方法给出空响应

PHP gettext方法给出空响应,php,gettext,zend-server,Php,Gettext,Zend Server,使用php gettext方法时,如: error_reporting(E_ALL); gettext("string"); //OR _("string"); 服务器给出一个空响应,绝对没有输出,甚至没有错误。 当注释这两种方法时,页面的工作方式与预期的一样 Firefox:连接已重置 Chrome:没有收到任何数据 Safari:{显示空页} 我正在使用:最新的Zend服务器在我的Mac上本地与OSX Mavericks(10.9.1)。 希望有人能帮上忙,我已经尝试了大约两周的时间来解决

使用php gettext方法时,如:

error_reporting(E_ALL);
gettext("string");
//OR
_("string");
服务器给出一个空响应,绝对没有输出,甚至没有错误。 当注释这两种方法时,页面的工作方式与预期的一样

Firefox:连接已重置

Chrome:没有收到任何数据

Safari:{显示空页}

我正在使用:最新的Zend服务器在我的Mac上本地与OSX Mavericks(10.9.1)。
希望有人能帮上忙,我已经尝试了大约两周的时间来解决这个问题,但似乎没有任何效果。

似乎在某些系统上setlocale()是不够的

设置语言对于某些系统和putenv()来说是不够的 应用于定义当前区域设置

当我添加以下内容时,问题得到了解决:

putenv('LC_ALL=0');