ecshop前台出现Notice: Undefined index

简介: 前台预览会出现Notice, Notice不是错误,是指通知的意思 Notice: Undefined index: lang in D:\wamp\www\includes\init.php on line 131Notice: Undefined index: lang in D:\wamp\www\includes\init.

前台预览会出现Notice,

Notice不是错误,是指通知的意思

Notice: Undefined index: lang in D:\wamp\www\includes\init.php on line 131

Notice: Undefined index: lang in D:\wamp\www\includes\init.php on line 139

Notice: Undefined index: lang in D:\wamp\www\includes\init.php on line 141

我们可以在init.php中屏蔽,在init.php的前几行找到

error_reporting(E_ALL);//E_ALL表示所有的都打开,错误等级设置


改成

error_reporting(E_ALL ^ E_NOTICE );//除去 E_NOTICE 之外的所有错误信息

相关文章
|
PHP
php模版引擎smarty出现Undefined index的解决方案
php模版引擎smarty出现Undefined index的解决方案
90 0
|
PHP
Undefined index: HTTP_REFERER 解决方法
Undefined index: HTTP_REFERER 解决方法
203 0
Undefined index: HTTP_REFERER 解决方法
|
JavaScript 关系型数据库 PHP
Notice: Undefined index: user in D:\phpStudy\WWW\js\ls\lsmc\php\add.php on line 9
原文:Notice: Undefined index: user in D:\phpStudy\WWW\js\ls\lsmc\php\add.php on line 9 (初用数据库(mysql)做用户登录注册这一块,遇到很多问题,通过搜索找到解决方案,把问题分享出来,希望可以帮助到和我一样问题的博友们,有问题还望多多指教。
1778 0
|
程序员 PHP
***PHP Notice: Undefined index: ..问题的解决方法
首先,这个不是错误,是warning。所以如果服务器不能改,每个变量使用前应当先定义。       方法1:服务器配置修改     修改php.ini配置文件,error_reporting = E_ALL & ~E_NOTICE       方法2:对变量进行初始化,规范书写(比较烦琐,因为有大量的变量)。
1300 0
|
PHP
php提示 Notice: Use of undefined constant name - assumed
我们知道php在数组中写变量有二几种方法,我们出现这种提示就是你写成了[name]这种所以会有Notice: Use of undefined constant name - assumed name提示了,解决办法参考下文。
1580 0
|
PHP
**PHP Notice: Undefined index:...问题的解决方法
这个问题可能是变量未定义造成的: if(!empty($current_user_id)){ $digg = $this->m_feed_digg->show_entity( array('digg_user_id' => $current_user_id, 'digg_feed_id' ...
1038 0
|
PHP
PHP Notice: Undefined index: ... 问题的解决方案
首先,这个不是错误,是warning。所以如果服务器不能改,每个变量使用前应当先定义。 方法1:服务器配置修改 修改php.ini配置文件,error_reporting = E_ALL & ~E_NOTICE 方法2:对变量进行初始化,规范书写(比较烦琐,因为有大量的变量)。
850 0
|
3天前
|
存储 JavaScript 前端开发
成功解决:Cannot read properties of undefined (reading ‘commit‘)
这篇文章提供了解决Vuex中"Cannot read properties of undefined (reading 'commit')"错误的两种方法:检查模板中的数据属性是否存在,以及确保在Vue实例中正确挂载了store对象。
成功解决:Cannot read properties of undefined (reading ‘commit‘)
|
7天前
|
定位技术 Apache
Echarts——Invalid geoJson format Cannot read property 'length' of undefined
Echarts——Invalid geoJson format Cannot read property 'length' of undefined
17 0