Jos*_*ian 0 python django templates django-templates literals
如果我想要一些文字在Django模板中出现,例如
{{Image.jpg|title}}
Run Code Online (Sandbox Code Playgroud)
我希望在HTML中输出(不解释)该文本,我该怎么办?
试试{% templatetag %}模板标签
{% templatetag openvariable %}Image.jpg|title{% templatetag closevariable %}
Run Code Online (Sandbox Code Playgroud)
http://docs.djangoproject.com/en/dev/ref/templates/builtins/#templatetag
| 归档时间: |
|
| 查看次数: |
442 次 |
| 最近记录: |