From 9eaf09e82bf39317374a859b16cda77273748ea0 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Thu, 5 Jul 2018 17:43:58 +0200 Subject: [PATCH] Removed the PHP templates from Symfony 4.0 docs --- translation/debug.rst | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/translation/debug.rst b/translation/debug.rst index bfa144d724e..fbaa98d13cb 100644 --- a/translation/debug.rst +++ b/translation/debug.rst @@ -10,25 +10,16 @@ When maintaining an application or bundle, you may add or remove translation messages and forget to update the message catalogues. The ``debug:translation`` command helps you to find these missing or unused translation messages templates: -.. configuration-block:: - - .. code-block:: twig - - {# messages can be found when using the trans/transchoice filters and tags #} - {% trans %}Symfony is great{% endtrans %} +.. code-block:: twig - {{ 'Symfony is great'|trans }} + {# messages can be found when using the trans/transchoice filters and tags #} + {% trans %}Symfony is great{% endtrans %} - {{ 'Symfony is great'|transchoice(1) }} - - {% transchoice 1 %}Symfony is great{% endtranschoice %} - - .. code-block:: php + {{ 'Symfony is great'|trans }} - // messages can be found when using the trans() and transChoice() methods - $view['translator']->trans("Symfony is great"); + {{ 'Symfony is great'|transchoice(1) }} - $view['translator']->transChoice('Symfony is great', 1); + {% transchoice 1 %}Symfony is great{% endtranschoice %} .. caution::