Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/heroku/2.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
Php Kohana ErrorException[8]_Php_Kohana_Kohana 3 - Fatal编程技术网

Php Kohana ErrorException[8]

Php Kohana ErrorException[8],php,kohana,kohana-3,Php,Kohana,Kohana 3,在安装和配置Kohana之后,我重命名了install.php文件(根据用户指南)。但是当我现在转到localhost/kohana时,我得到以下错误: ErrorException [ 8 ]: Array to string conversion ~ SYSPATH/classes/Kohana/Log/Writer.php [ 81 ] 我在网上其他地方找不到解决方案。有人知道如何解决这个问题吗?谢谢 这是Kohana 3.3版本的错误。查看更多详细信息。这是该错误的修补程序。希望这对

在安装和配置Kohana之后,我重命名了install.php文件(根据用户指南)。但是当我现在转到localhost/kohana时,我得到以下错误:

 ErrorException [ 8 ]: Array to string conversion ~ SYSPATH/classes/Kohana/Log/Writer.php [ 81 ]

我在网上其他地方找不到解决方案。有人知道如何解决这个问题吗?谢谢

这是Kohana 3.3版本的错误。查看更多详细信息。

这是该错误的修补程序。希望这对其他人有帮助

classes/Kohana/Log/Writer.php

 public function format_message(array $message, $format = "time --- level: body in   file:line")
    {
     $message['time'] = Date::formatted_time('@'.$message['time'], Log_Writer::$timestamp, Log_Writer::$timezone, TRUE);
     $message['level'] = $this->_log_levels[$message['level']];

-    // FIX: $message should consist of an array of strings
-    $message = array_filter($message, 'is_string');
-
-    $string = strtr($format, $message);
+    $string = strtr($format, array_filter($message, 'is_scalar'));

     if (isset($message['additional']['exception']))
     {
       $message['body'] = $message['additional']['exception']->getTraceAsString();
       $message['level'] = $this->_log_levels[Log_Writer::$strace_level];

 -     $string .= PHP_EOL.strtr($format, $message);
 +     $string .= PHP_EOL.strtr($format, array_filter($message, 'is_scalar'));
     }

   return $string;

注意,“+”表示添加了一行,“-”表示从v3.3中删除了一行,Kohana有自己的论坛。这不是一个编程问题,而是一个软件产品支持问题。感谢您提供的信息:)这是一个仅链接的答案。虽然此链接可以回答问题,但最好在此处包含答案的基本部分,并提供链接以供参考。如果链接页面发生更改,则仅链接的答案可能无效。