安装时出现warning:date_default_timezone_get(): 什么原因?
2016-07-07 15:20 来源:www.chinab4c.com 作者:ecshop专家
安装程序时出现 Warning: date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'UTC' for '8.0/no DST' instead in F:\yolin_www\ecshop\install\includes\lib_installer.php on line 223 这个如何解决,求帮忙解决 |
回答:
没人回答么? |
data下有个config.php中有时区配置信息呢 可以使用服务器时间设置 utc 或者使用时区设置 $timezone = "Asia/Shanghai"; |
data/目录下没有config.php这个文件啊 |
我把提示的错误内容改成"Asia/Shanghai"; function get_local_timezone() { if (PHP_VERSION >= '5.1') { $local_timezone = "Asia/Shanghai"; } 结果安装的时候出现如下错误 安装数据............失败 Warning: date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'UTC' for '8.0/no DST' instead in F:\yolin_www\ecshop\includes\cls_mysql.php on line 163 Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'UTC' for '8.0/no DST' instead in F:\yolin_www\ecshop\includes\cls_mysql.php on line 165 Warning: date_default_timezone_get(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'UTC' for '8.0/no DST' instead in F:\yolin_www\ecshop\includes\cls_mysql.php on line 173 OK |
date_default_timezone_get(): It is not safe to rely on the system's timezone settings 没大碍的 |
今天装这个,试的办法基本上无外乎以下几种。 1, 修改PHP安装目录下的php.ini文件大约958行为以下. [Date] ; Defines the default timezone used by the date functi** ; http://php.net/date.timezone date.timezone = "UTC" 结果, 无效。 2. 修改/data/目录下config.php文件 $timezone = "UTC"; 结果无效。 3,就是所谓在有date_default_timezone_get();前加设置时区的代码。 date_default_timezone_set('UTC'); 结果: 无效。 ------------------------------------------------------------------------------------------- 最后这个方法让我的解决了,这家伙不错。 王涛 http://wangtao.name/blog/2010/03/16/install_ecs2-7-1_error/ 安装完成后,虽然有报错,不要理会。(你看数据库,确实表已经建立了) 在/data/目录下建一个文件install.txt 内容写上"ECSHOP INSTALLED" 扩展名改为.lock 最终就是install.lock 这时搞定。 大家看看行不行,我今天安装的版本是 V2.7.2 |
这个问题 哪有那么复杂哦。。 找到php.ini搜索 date.timezone 前面的 分号去掉。date.timezone = "Asia/Shanghai" 就OK了。 必须的是。。。修改完后 重启 apache我估计 楼上就是没重启apache |
好用谢谢了 |
最近更新
常用插件
- ecshop选择下单时间插件
ecshop选择下单时间插件主要是根据不同的下单配送要求,在ecshop购物车...
- ecshop二次开发售后维修卡
插件介绍: 本插件是用于专门从事电子,信息,软件等售后服务关键比...
- ecshop供应商插件免费下载
ecshop供应商插件免费下载...
- ecshop按分类筛选销售排行
ecshop按分类筛选销售排行...
- ecshop快递发货单打印商品
ecshop快递发货单打印商品信息,大家都知道ecshop快递单打印的时候,只能...
ecshop热门问答
ecshop热门资料
ecshop双模手机
ecshop聚合
ecshop收藏文章
会员级别
ecshopexist
ecshopfalsh
ecshop數據庫
ecshop师兄
Editable
ecshop不到
ecshop分卷
ecshop上级
ecshop姐姐
ecshop服务器时间
ecshop伺服
ecshopkefu
ecshop礼品赠送索取
ecshop有害信息
ecshop挑战
ecshop海淀区
ecshopelement
ecshop仪器
ecshop代销
ecshop网站文章进不去
ecshop创意
ecshop太空
ecshop意见
ecshop价格上调
ecshopIntel
ecshop图片大小