CONFIG_KEY
CONFIG_KEY
Displays an access denied error page if the response status is 403.
If the MvcEvent::Response status has been set to 403 it creates a View Model to render the access denied template, inserts it into the MvcEvent and ends propagation of the dispatch event.
If self::renderLayout is true it will also inject the access denied View Model into the layout View Model. IMPORTANT make sure your layout never contains any sensitive information before you enable this.
Configuration Example array(
'access_denied_strategy' => array(
'renderLayout' => BOOLEAN,
'template' => template/alias/or/path,
)
);
setRenderLayout(boolean $flag) : \Spork\Mvc\Listener\AccessDeniedStrategy
Set render layout flag
boolean | $flag |
setTemplate(\Spork\Mvc\Listener\unknown $template) : \Spork\Mvc\Listener\AccessDeniedStrategy
Set access denied template
\Spork\Mvc\Listener\unknown | $template |