【发布时间】:2015-09-10 19:56:46
【问题描述】:
无法为 Ajax 聊天运行安装脚本。看来函数调用可以找到适当的 $filename,所以我无法确定无效参数是什么。
in file [ROOT]/phpbb/di/container_builder.php on line 291: file_put_contents(C:/inetpub/wwwroot/phpbb3/chat/../cache/container_C:/inetpub/wwwroot/phpbb3/chatslashdotdotslash.php): failed to open stream: Invalid argument
这是第 284-291 行:
protected function dump_container($container_filename)
{
$dumper = new PhpDumper($this->container);
$cached_container_dump = $dumper->dump(array(
'class' => 'phpbb_cache_container',
'base_class' => 'Symfony\Component\DependencyInjection\ContainerBuilder',
));
file_put_contents($container_filename, $cached_container_dump);
}
$container_filename 的函数调用是
protected function get_container_filename()
{
$filename = str_replace(array('/', '.'), array('slash', 'dot'), $this->phpbb_root_path);
return $this->phpbb_root_path . 'cache/container_' . $filename . '.' . $this->php_ext;
}
我认为 $cached_container_dump 的函数变量可能是问题所在,如上面第 2 行所示。我不确定是否找到了 base_class,因为它不在命名空间中。几天来一直试图遵循这个......任何帮助将不胜感激。
var_dump($dumper) 的结果:这是否意味着数组正在返回一个对象?
object(Symfony\Component\DependencyInjection\Dumper\PhpDumper)#13 (7) { ["inlinedDefinitions":"Symfony\Component\DependencyInjection\Dumper\PhpDumper":private]=> object(SplObjectStorage)#3325 (1) { ["storage":"SplObjectStorage":private]=> array(198)
【问题讨论】: