如何通过配置屏蔽Yii框架的错误提示信息?
- 内容介绍
- 文章标签
- 相关推荐
本文共计231个文字,预计阅读时间需要1分钟。
要显示YII框架中的错误提示,请按照以下步骤操作:
1. 打开入口文件index.php;
2.在文件中添加以下代码:
3.保存并关闭文件。
yii屏蔽错误提示的方法:首先打开入口文件“index.php”;然后加上“error_reporting (0);”;最后注释“defined('YII_DEBUG') or define('YII_DEBUG',true);”即可。
yii 屏蔽错误提示
在入口文件index.php里处理:
加上: error_reporting (0);
注释: defined('YII_DEBUG') or define('YII_DEBUG',true);
推荐:《yii教程》
另外: 错误处理器的注册是在应用中的constructor方法中进行的,使用了PHP函数set_exception_handler 和set_error_handler。
本文共计231个文字,预计阅读时间需要1分钟。
要显示YII框架中的错误提示,请按照以下步骤操作:
1. 打开入口文件index.php;
2.在文件中添加以下代码:
3.保存并关闭文件。
yii屏蔽错误提示的方法:首先打开入口文件“index.php”;然后加上“error_reporting (0);”;最后注释“defined('YII_DEBUG') or define('YII_DEBUG',true);”即可。
yii 屏蔽错误提示
在入口文件index.php里处理:
加上: error_reporting (0);
注释: defined('YII_DEBUG') or define('YII_DEBUG',true);
推荐:《yii教程》
另外: 错误处理器的注册是在应用中的constructor方法中进行的,使用了PHP函数set_exception_handler 和set_error_handler。

