【发布时间】:2013-08-07 02:54:02
【问题描述】:
我正在尝试将 php zend 文件从服务器运行到本地主机(迁移)。我已经更改了我知道的配置,但是当我尝试运行它时,浏览器中显示以下错误;
Array ( [0] => Zend_Controller_Dispatcher_Exception Object
(
[message:protected] => Invalid controller specified (www)
[string:Exception:private] => [code:protected] => 0
[file:protected] => C:\xampp\htdocs\www\html\library\Zend\Controller\Dispatcher\Standard.php
[line:protected] => 241
[trace:Exception:private] => Array (
[0] => Array (
[file] => C:\xampp\htdocs\www\html\library\Zend\Controller\Front.php
[line] => 936
[function] => dispatch
[class] => Zend_Controller_Dispatcher_Standard
[type] => -> [args] => Array (
[0] => Zend_Controller_Request_Http Object (
[_paramSources:protected] => Array (
[0] => _GET [1] => _POST )
[_requestUri:protected] => /www/html/web/
[_baseUrl:protected] =>
[_basePath:protected] =>
[_pathInfo:protected] => /www/html/web/
[_params:protected] => Array (
[controller] => www
[action] => html
[module] => default
)
[_aliases:protected] => Array ( )
[_dispatched:protected] => 1
[_module:protected] => default
[_moduleKey:protected] => module
[_controller:protected] => www
[_controllerKey:protected] => controller
[_action:protected] => html
[_actionKey:protected] => action
)
[1] => Zend_Controller_Response_Http Object (
[_body:protected] => Array ( )
[_exceptions:protected] => Array RECURSION
[_headers:protected] => Array ( )
[_headersRaw:protected] => Array ( )
[_httpResponseCode:protected] => 200
[_isRedirect:protected] =>
[_renderExceptions:protected] =>
[headersSentThrowsException] => 1
)
)
)
[1] => Array (
[file] => C:\xampp\htdocs\www\html\index.php
[line] => 5
[function] => dispatch
[class] => Zend_Controller_Front
[type] => ->
[args] => Array ( )
)
)
[previous:Exception:private] =>
)
)
你们能帮我解决这个错误吗?提前致谢
【问题讨论】:
-
如果你从windows迁移到linux系统的话可能会是个问题。确保您调用控制器的情况与定义的情况相同。
-
你检查过php错误日志吗?这可能更有用。
-
@RiggsFolly 异常说明了在这种情况下错误日志必须说明的内容
-
这是从 windows 到 windows,只是从以前的开发人员到我。我需要在本地运行它来更改文件。
-
您是否在此文件 windows/system32/drivers/etc/hosts 中进行了任何更改
标签: php arrays zend-framework exception localhost