【发布时间】:2009-08-01 17:39:46
【问题描述】:
我有一个简单的 ZF,它已经很好用了。 我已将其设置为在子文件夹中工作,因此我使用 localhost/zftutorial URL 访问它。
现在是调试的时候了,但是当我在 Eclipse 中执行调试器时,它会附加调试 URL 参数(如 XDEBUG_SESSION_START=ECLIPSE_DBGP),这会破坏一切,我开始收到以下消息:
> Zend_Controller_Dispatcher_Exception:在第 241 行的 C:\Program Files\VertrigoServ\www\library\Zend\library\Zend\Controller\Dispatcher\Standard.php 中指定了无效的控制器 (index.php)
我尝试将 localhost/zftutorial 和 localhost/zftutorial/public/index.php 都设置为调试器的启动 URL,但仍然收到相同的消息。
看起来 ZF 喜欢干净的 URL 名称,但 Eclipse 想要带有 php 扩展的脚本,但需要控制器名称。无论我使用哪种调试选项,Ecpise 都会尝试从 不是 Zend 风格的 URL - http://localhost/zftutorial/index.php
我想这可以通过两种方式解决:
- 以某种方式配置 Eclipse 以使用带有调试参数的正确 URL,例如 localhost/zftutorial
- 将 localhost/zftutorial/public/index.php 的重写规则设置为重写为 localhost/zftutorial(对吗?)
【问题讨论】:
标签: eclipse debugging zend-framework mod-rewrite