TranslateTokenParser
class TranslateTokenParser extends Twig_TokenParser
Use the I18n\I18n::translate function
{% translate %}
your string index
{% endtranslate %}
{% translate "your string index" %}
{% translate 'fr' %}
your string index
{% endtranslate %}
{% translate 'fr' "your string index" %}
{% translate { 'arg1': "value1", 'arg2': 567 } %}
your string index
{% endtranslate %}
{% translate { 'arg1': "value1", 'arg2': 567 } "your string index" %}
Methods
parse(
Twig_Token $token)
No description
getTag()
No description
isEndTag(
Twig_Token $token)
No description