This is my first experience using the Zend Framework. I am trying to follow the Quick Start Guide . Everything worked as expected until I got to the Error Controller and View section. When I go to a page that does not exist, instead of getting an error page, I get a Fatal Error screen dump (in all its glory):
Fatal error: uncaught exception 'Zend_Controller_Dispatcher_Exception' with the message "Invalid controller specified (error)" in /home/.fantasia/bcnewman/foo.com/library/Zend/Controller/Dispatcher/Standard.php:249 Stack trace: # 0 / home / .fantasia / bcnewman / foo.com / library / Zend / Controller / Front.php (946): Zend_Controller_Dispatcher_Standard-> submit (Object (Zend_Controller_Request_Http), Object (Zend_Controller_Response_Http)) # 1 / manfoo .com / public / index.php (42): Zend_Controller_Front-> dispatch () # 2 {main} is thrown at /home/.fantasia/bcnewman/foo.com/library/Zend/Controller/Dispatcher/Standard.php on line 249
I donβt think that this is caused by a syntax error on my part (the contents of the example file from the tutorial were copied and pasted), and I believe that the application directory structure is correct:
./application ./application/controllers ./application/controllers/IndexController.php ./application/controllers/ErrorHandler.php ./application/views ./application/views/scripts ./application/views/scripts/index ./application/views/scripts/index/index.phtml ./application/views/scripts/error ./application/views/scripts/error/error.phtml ./application/bootstrap.php ./public ./public/index.php
And finally, the look of IndexController and index.phtml work.
source share