Skip to content

Commit

Permalink
minor #4353 [Cookbook][Controller] fix route prefix in PHP code examp…
Browse files Browse the repository at this point in the history
…le (xabbuh)

This PR was merged into the master branch.

Discussion
----------

[Cookbook][Controller] fix route prefix in PHP code example

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | no
| Applies to    | 2.6
| Fixed tickets |

Commits
-------

16daca4 fix route prefix in PHP code example
  • Loading branch information
wouterj committed Oct 31, 2014
2 parents 83ed35b + 16daca4 commit 217bf5f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cookbook/controller/error_pages.rst
Expand Up @@ -191,7 +191,7 @@ To use this feature, you need to have a definition in your
$collection->addCollection(
$loader->import('@TwigBundle/Resources/config/routing/errors.xml')
);
$collection->addPrefix("/error");
$collection->addPrefix("/_error");
return $collection;
Expand Down Expand Up @@ -326,7 +326,7 @@ another page or rendering specialized error pages.

If your listener calls ``setResponse()`` on the
:class:`Symfony\\Component\\HttpKernel\\Event\\GetResponseForExceptionEvent`,
event propagation will be stopped and the response will be sent to
event propagation will be stopped and the response will be sent to
the client.

This approach allows you to create centralized and layered error
Expand All @@ -338,7 +338,7 @@ several) listeners deal with them.

To see an example, have a look at the `ExceptionListener`_ in the
Security Component.

It handles various security-related exceptions that are thrown in
your application (like :class:`Symfony\\Component\\Security\\Core\\Exception\\AccessDeniedException`)
and takes measures like redirecting the user to the login page,
Expand Down

0 comments on commit 217bf5f

Please sign in to comment.