Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit89e38ef

Browse files
Removed invalid examples
Templating isn't a service in Symfony 4+ (even after `composer req templating`), so probably we're looking for the twig service.The Router service isn't public and can therefor not be called from the container:```Information for Service "router.default"======================================== ---------------- ----------------------------------------------- Option Value ---------------- ----------------------------------------------- Service ID router.default Class Symfony\Bundle\FrameworkBundle\Routing\Router Tags - Calls setConfigCacheFactory Public no Synthetic no Lazy no Shared yes Abstract no Autowired no Autoconfigured no ---------------- -----------------------------------------------```
1 parent5d4254e commit89e38ef

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

‎controller.rst‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -299,9 +299,7 @@ If you extend the base ``Controller`` class, you can access :ref:`public service
299299
via the:method:`Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller::get`
300300
method. Here are several common services you might need::
301301

302-
$templating = $this->get('templating');
303-
304-
$router = $this->get('router');
302+
$twig = $this->get('twig');
305303

306304
$mailer = $this->get('mailer');
307305

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp