Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/284.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
加载主页后在UserFrosting上记录php错误_Php_Error Handling_Userfrosting - Fatal编程技术网

加载主页后在UserFrosting上记录php错误

加载主页后在UserFrosting上记录php错误,php,error-handling,userfrosting,Php,Error Handling,Userfrosting,我正在尝试安装UserFrosting 在加载主页之后,我得到了这些错误 [01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 6. Composer\Autoload\includeFile() C:\Server\userfrosting\vendor\composer\ClassLoader.php:301 [01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 5. Composer\Autoload\ClassLoader-&g

我正在尝试安装UserFrosting 在加载主页之后,我得到了这些错误

[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 6. Composer\Autoload\includeFile() C:\Server\userfrosting\vendor\composer\ClassLoader.php:301
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 5. Composer\Autoload\ClassLoader->loadClass() C:\Server\userfrosting\initialize.php:25 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 4. spl_autoload_call() C:\Server\userfrosting\initialize.php:25 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 3. UserFrosting\UserFrosting->setupGuestEnvironment() C:\Server\userfrosting\initialize.php:193 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 2. require_once() C:\Server\index.php:10 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP 1. {main}() C:\Server\index.php:0 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP Stack trace: 
[01-Oct-2016 18:28:29 Asia/Jerusalem] PHP Strict standards: Declaration of UserFrosting\User::fresh() should be compatible with Illuminate\Database\Eloquent\Model::fresh(array $with = Array) in C:\Server\userfrosting\models\database\User.php on line 570 
我找不到问题所在
感谢您的帮助错误
PHP严格标准:UserFrosting\User::fresh()的声明应与C:\Server\UserFrosting\models\Database\User::fresh(array$with=array)中C:\Server\UserFrosting\models\Database\User.PHP第570行的
UserFrosting\User::fresh()兼容
方法应接受与
illighted\Database\Eloquent\Model::fresh(array$with=array)
相同类型的参数

可使用以下代码复制此问题:

test.php

要修复它,我们只需根据父方法修改派生类中的
test
方法:

B类扩展了A类{
公共函数测试($arg='X value'){
回声法;
}
}
运行脚本:

$ php test.php
PHP Warning:  Declaration of B::test() should be compatible with A::test($arg = 'default va...') in /home/ruslan/tmp/src/test.php on line 12
$ php test.php 
B::test
$ php test.php 
B::test