Bor*_*ris 5 django django-templates
我有一个字符串,我想通过"linebreaks"过滤器传递.
{% trans "my string"|linebreaks %}
Run Code Online (Sandbox Code Playgroud)
不行.
还有另外一种方法吗?
见filter.
{% filter force_escape|lower %}
{% blocktrans %}This text will be translated, HTML-escaped, and will appear in all lowercase.{% endblocktrans %}
{% endfilter %}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
1195 次 |
| 最近记录: |