|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2008-02-11 22:08 UTC] johnston dot joshua at gmail dot com
Description:
------------
When an exception is thrown and not caught and html_errors = on the Fatal Error text is only partially formatted. When you 'view source' in your web browser you can see the stact trace is nicely formatted but has no format for content-type: text/html
Actual result:
--------------
<br />
<b>Fatal error</b>: Uncaught exception 'Zend_Controller_Action_Exception' with message 'Portal_TrialController::helloAction() does not exist and was not trapped in __call()' in /code/dev/php/Zend/Controller/Action.php:480
Stack trace:
#0 [internal function]: Zend_Controller_Action->__call('helloAction', Array)
#1 /code/dev/php/Zend/Controller/Action.php(497): Portal_TrialController->helloAction()
#2 /code/dev/php/Zend/Controller/Dispatcher/Standard.php(238): Zend_Controller_Action->dispatch('helloAction')
#3 /code/dev/php/Zend/Controller/Front.php(920): Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http))
#4 /home/jjohnston/svn/dev/www/bootstrap.php(96): Zend_Controller_Front->dispatch()
#5 /home/jjohnston/svn/dev/www/bootstrap.php(6): MailWise_Bootstrap::main()
#6 {main}
thrown in <b>/code/dev/php/Zend/Controller/Action.php</b> on line <b>480</b><br />
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Dec 14 16:00:01 2025 UTC |
The Exception and Fatal Error work just fine. I am reporting this as a bug because error output has newlines in it but the HTML display does not reflect this format. I would expect the stack trace would be wrapped in <pre></pre> or even some sort of list so that it is readable in HTML output instead of all run together. If you view it in a browser you see: Stack trace:#0 [internal function]: Zend_Controller_Action->__call('helloAction', Array) #1 /code/dev/php/Zend/Controller/Action.php(497):Portal_TrialController->helloAction() #2 /code/dev/php/Zend/Controller/Dispatcher/Standard.php(238):Zend_Controller_Action->dispatch('helloAction') #3 /code/dev/php/Zend/Controller/Front.php(920):Zend_Controller_Dispatcher_Standard->dispatch(Object(Zend_Controller_Request_Http), Object(Zend_Controller_Response_Http)) #4 /home/jjohnston/svn/dev/www/bootstrap.php(96): Zend_Controller_Front->dispatch() #5 /home/jjohnston/svn/dev/www/bootstrap.php(6): MW_Bootstrap::main() #6 {main} thrown in <b>/code/dev/php/Zend/Controller/Action.php</b> on line Notice the text is displayed in a long line without any visual separation. This is true of any thrown but not caught Exception, not Zend Framework specific. The error message does add a <br /> before and after the error text.