我有这个新安装的Yii2先进的,想知道如果有人曾经遇到这个错误后,从前端登录?
您采用了什么解决方案来解决此问题?
下面是我的composer.json
{
"name": "yiisoft/yii2-app-advanced",
"description": "Yii 2 Advanced Project Template",
"keywords": ["yii2", "framework", "advanced", "project template"],
"homepage": "http://www.yiiframework.com/",
"type": "project",
"license": "BSD-3-Clause",
"support": {
"issues": "https://github.com/yiisoft/yii2/issues?state=open",
"forum": "http://www.yiiframework.com/forum/",
"wiki": "http://www.yiiframework.com/wiki/",
"irc": "irc://irc.freenode.net/yii",
"source": "https://github.com/yiisoft/yii2"
},
"minimum-stability": "stable",
"require": {
"php": ">=5.6.0",
"yiisoft/yii2": "~2.0.14",
"yiisoft/yii2-bootstrap4": "~2.0.0",
"yiisoft/yii2-swiftmailer": "~2.0.0 || ~2.1.0"
},
"require-dev": {
"yiisoft/yii2-debug": "~2.1.0",
"yiisoft/yii2-gii": "~2.2.0",
"yiisoft/yii2-faker": "~2.0.0",
"codeception/codeception": "^4.0",
"codeception/module-asserts": "^1.0",
"codeception/module-yii2": "^1.0",
"codeception/module-filesystem": "^1.0",
"codeception/verify": "~0.5.0 || ~1.1.0",
"symfony/browser-kit": ">=2.7 <=4.2.4"
},
"config": {
"process-timeout": 1800,
"fxp-asset": {
"enabled": false
}
},
"repositories": [
{
"type": "composer",
"url": "https://asset-packagist.org"
}
]
}
字符串
3条答案
按热度按时间mf98qq941#
从php 8.1开始,你不能在class_exists函数中放置空值。要解决这个问题,请在\vendor\yiisoft\yi2-debug\src\panel.php文件中替换第90/91行
字符串
与
型
这不是一个好的解决方案,因为我们正在编辑yii的源代码,但是工作:)Yii的2.0.46版本可能会解决这个问题
kmbjn2e32#
Yii2似乎与PHP 8.1版本不兼容。我不得不在我的macbook上回到7.4版的PHP
6ovsh4lw3#
在634 b 9 cc 5e 89 bcc 65091 fe 25 ea 2b 5538 b5 bc 5ce 76中修复了,所以当新版本出来的时候它会被修复,同时你可以使用“yiisoft/yii 2-debug”:“dev-master#...”
https://github.com/yiisoft/yii2-debug/issues/482