Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Usually if you used the CLI to create the zend project it will already be able to do what you request. If you go the scripts/view/errors/error.phtml that will be the phtml file you can use to create the view you are looking to use.</p> <p>Although if you did not use the CLI to create the zend project bellow is the generated ErrorController used</p> <pre><code>&lt;?php class ErrorController extends Nanaly_Controller { public function errorAction() { $errors = $this-&gt;_getParam('error_handler'); switch ($errors-&gt;type) { case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_NO_ROUTE: case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_NO_CONTROLLER: case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_NO_ACTION: // 404 error -- controller or action not found $this-&gt;getResponse()-&gt;setHttpResponseCode(404); $this-&gt;view-&gt;message = 'Page not found'; break; default: // application error $this-&gt;getResponse()-&gt;setHttpResponseCode(500); $this-&gt;view-&gt;message = 'Application error'; break; } // Log exception, if logger available if ($log = $this-&gt;getLog()) { $log-&gt;crit($this-&gt;view-&gt;message, $errors-&gt;exception); } // conditionally display exceptions if ($this-&gt;getInvokeArg('displayExceptions') == true) { $this-&gt;view-&gt;exception = $errors-&gt;exception; } $this-&gt;view-&gt;request = $errors-&gt;request; } public function getLog() { $bootstrap = $this-&gt;getInvokeArg('bootstrap'); if (!$bootstrap-&gt;hasPluginResource('Log')) { return false; } $log = $bootstrap-&gt;getResource('Log'); return $log; } } </code></pre> <p>Note: this Controller was generated using Zend Version 1.10.0</p> <p>and the view should be placed in the same location as stated earlier.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload