Skip to content

Commit c443d1c

Browse files
committed
minor #8394 Page creation article (tiwiex, javiereguiluz)
This PR was merged into the 2.7 branch. Discussion ---------- Page creation article included some clarity on creating the controller bundle. not a syntax error. The step is hidden in the code while the instruction to extend Symfony Controller with the LuckyController. Commits ------- d2ff7d6 Rewords d89d2b2 added the step to include "use Symfony\Bundle\FrameworkBundle\Controller\Controller;" before Lucky Controller extends the base controller class. This was mentioned in the code but could easily have been missed as a step. I missed that and didn't realize it was a new line in the code. I think the necessary Framework bundles should all have been listed. 9e9f28e Uncommemted line 10: ** @route("/lucky/number"). I was getting a routing error.
2 parents 4a583b2 + d2ff7d6 commit c443d1c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

page_creation.rst

+4-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,10 @@ If you're returning HTML from your controller, you'll probably want to render
9494
a template. Fortunately, Symfony comes with `Twig`_: a templating language that's
9595
easy, powerful and actually quite fun.
9696

97-
First, make sure that ``LuckyController`` extends Symfony's base
97+
First, import the Symfony's base
98+
:class:`Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller` class as shown
99+
in line 5 below. Then, make sure that ``LuckyController`` extends from it::
100+
98101
:class:`Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller` class::
99102

100103
// src/AppBundle/Controller/LuckyController.php

0 commit comments

Comments
 (0)