File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -804,14 +804,17 @@ The controller might look like this:
804804 Notice that Symfony adds the string ``Controller `` to the class name (``Blog ``
805805=> ``BlogController ``) and ``Action `` to the method name (``show `` => ``showAction ``).
806806
807+ You could also refer to this controller using its fully-qualified class name
808+ and method: ``Acme\BlogBundle\Controller\BlogController::showAction ``.
809+ But if you follow some simple conventions, the logical name is more concise
810+ and allows more flexibility.
811+
807812.. note ::
808813
809- Symfony also supports two other controller formats. The first contains
810- one colon separator (e.g. ``service_name:indexAction ``) and refers to
811- the controller as a service (see :doc: `/cookbook/controller/service `).
812- The second is formatted like ``ControllerClassName::methodName ``. When
813- Symfony sees this format, it will try to create a new instance of ``ControllerClassName ``
814- and then call the ``methodName `` method.
814+ In addition to using the logical name or the fully-qualified class name,
815+ Symfony supports a third way of referring to a controller. This method
816+ uses just one colon separator (e.g. ``service_name:indexAction ``) and
817+ refers to the controller as a service (see :doc: `/cookbook/controller/service `).
815818
816819Route Parameters and Controller Arguments
817820-----------------------------------------
You can’t perform that action at this time.
0 commit comments