View Single Post
  #1 (permalink)  
Old 12-15-2007, 11:18 AM
ignace ignace is offline
Junior Member
 
Join Date: Dec 2007
Posts: 8
Lightbulb setControllerDirectory apparently does not set anything

PHP Code:
$frontController Zend_Controller_Front::getInstance();
$frontController->setControllerDirectory('D:\application\controllers');
$frontController->setBaseUrl('http://localhost/');
$frontController->dispatch(); 
returns the following error report:

Code:
Warning:  include_once(IndexController.php) [function.include_once]: failed to open stream: No such file or directory in D:\application\Bootstrap.php on line 5

Warning:  include_once() [function.include_once]: Failed opening 'IndexController.php' for inclusion (include_path='.;D:\libraries') in D:\application\Bootstrap.php on line 5

Warning:  include_once(IndexController.php) [function.include_once]: failed to open stream: No such file or directory in D:\application\Bootstrap.php on line 5

Warning:  include_once() [function.include_once]: Failed opening 'IndexController.php' for inclusion (include_path='.;D:\libraries') in D:\application\Bootstrap.php on line 5
hello world
it apparently does do load my view as it contains the 'hello world' output.
i did not added the controller directory to the include_path, why would i otherwise be setting the controller directory?

i am using zend framework 1.0.3, can anyone shed some light on the problem?

thanks in advance,
a zend forum regular

PARTIALLY SOLVED: created an instance of Zend_Controller_Dispatcher_Standard and called the method setControllerDirectory() on the Zend_Controller_Dispatcher_Standard instance and added it as default dispatcher for the front controller $frontController->setDispatcher($dispatcher);

well the problem that i now have, is that everything is loaded but the lookup effect is still hanging, so meaning i still get the above warning level error report (e.g. include_once(IndexController.php)) while my controller/action has been processed and the view parsed..

Last edited by ignace : 12-15-2007 at 04:51 PM.
Reply With Quote