PHP简单html dom:apache崩溃
我使用的是简单HTML Dom。我正在尝试运行以下程序:(使用WAMP) 如果我注释掉foreach循环,它运行良好。 否则,apache将崩溃 一个重要的注意事项是:如果我注释掉foreach循环的内部,它仍然会崩溃。 我添加了var转储以确保数组中有有效的项 编辑: Apache日志:PHP简单html dom:apache崩溃,php,simple-html-dom,Php,Simple Html Dom,我使用的是简单HTML Dom。我正在尝试运行以下程序:(使用WAMP) 如果我注释掉foreach循环,它运行良好。 否则,apache将崩溃 一个重要的注意事项是:如果我注释掉foreach循环的内部,它仍然会崩溃。 我添加了var转储以确保数组中有有效的项 编辑: Apache日志: [Tue Jul 10 16:53:53 2012] [notice] Parent: child process exited with status 255 -- Restarting. [Tue Jul
[Tue Jul 10 16:53:53 2012] [notice] Parent: child process exited with status 255 -- Restarting.
[Tue Jul 10 16:53:53 2012] [notice] Apache/2.2.22 (Win64) PHP/5.3.13 configured -- resuming normal operations
[Tue Jul 10 16:53:53 2012] [notice] Server built: May 13 2012 19:41:17
[Tue Jul 10 16:53:53 2012] [notice] Parent: Created child process 5568
[Tue Jul 10 16:53:53 2012] [notice] Child 5568: Child process is running
[Tue Jul 10 16:53:53 2012] [notice] Child 5568: Acquired the start mutex.
[Tue Jul 10 16:53:53 2012] [notice] Child 5568: Starting 64 worker threads.
[Tue Jul 10 16:53:53 2012] [notice] Child 5568: Starting thread to listen on port 80.
[Tue Jul 10 16:53:53 2012] [notice] Child 5568: Starting thread to listen on port 80.
尝试改变
$this::ctrim($text[0]->innertext);
到
或
$obj->method
是一个实例调用。
Class::method
是一个静态调用。
$this::method
可能做了一些奇怪的事情…尝试更改
$this::ctrim($text[0]->innertext);
到
或
$obj->method
是一个实例调用。
Class::method
是一个静态调用。
$this::method
可能有点奇怪…这可能是内存泄漏:因为你的apache说: 子进程已退出,状态为255 请参见此处:
由于php5循环引用内存泄漏,在创建DOM之后 对象,则必须调用$dom->clear()以释放内存 多次使用file_get_dom()
从这里开始:这可能是内存泄漏:
因为你的apache说: 子进程已退出,状态为255 请参见此处:
由于php5循环引用内存泄漏,在创建DOM之后 对象,则必须调用$dom->clear()以释放内存 多次使用file_get_dom()
从这里开始:apache怎么说?你能发布错误日志吗?apache怎么说?你能发布错误日志吗?问题在foreach循环中,我对循环中的所有内容都进行了注释,只留下了迭代,但它仍然会导致崩溃。问题在foreach循环中,我对循环中的所有内容进行了注释,只留下了迭代,但它仍然会导致崩溃。是的!我忘了我有一个调用页面的循环,当我调用file\u get\u html时,我没有释放内存。非常感谢你!是的!我忘了我有一个调用页面的循环,当我调用file\u get\u html时,我没有释放内存。非常感谢你!
self::ctrim($text[0]->innertext);
$this->ctrim($text[0]->innertext);