本地主机上的locale_get_default()函数问题 [英] locale_get_default() function issue on localhost
问题描述
我在localhost上使用wampserver;
Im using wampserver on localhost with;
- PHP 5.3.13
- Apache 2.2.22
- 启用了php_intl.dll扩展名
但是使用locale_get_default()
函数时出现以下错误
But i got following error while using locale_get_default()
function
严重错误:调用
Fatal error: Call to undefined function locale_get_default() in
或使用Locale::getDefault()
函数
致命错误:找不到类'Locale'
Fatal error: Class 'Locale' not found in
推荐答案
解决了以下链接
http://forum.wampserver.com/read.php?2, 80704,116793
好,我知道了.看来Apache无法找到icu * .dll 文件(在php目录中).
Ok, I got it to work. It looks like Apache can't find the icu*.dll files (in the php directory).
因此,一种解决方案是添加"C:\ wamp \ bin \ php \ php5.3.9"(或类似的名称) 目录).
So, one solution is to add "C:\wamp\bin\php\php5.3.9" (or similar directory) to your system PATH.
另一种解决方案是将icu * .dll文件复制到您的apache的bin中 目录.
The other solution is to copy the icu*.dll files to your apache's bin directory.
第三个选择是将icu * .dll文件复制到Windows系统 目录(system32或SysWOW64).
A third option is to copy the icu*.dll files to your Windows system directory (system32 or SysWOW64).
这篇关于本地主机上的locale_get_default()函数问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!