浏览代码

Added syntax highlighting to CSRF example.

B. J. Potter 8 年之前
父节点
当前提交
261738990e
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      docs/ref/csrf.txt

+ 3 - 1
docs/ref/csrf.txt

@@ -37,7 +37,9 @@ To take advantage of CSRF protection in your views, follow these steps:
    you want to protect (see below).
 
 2. In any template that uses a POST form, use the :ttag:`csrf_token` tag inside
-   the ``<form>`` element if the form is for an internal URL, e.g.::
+   the ``<form>`` element if the form is for an internal URL, e.g.:
+
+   .. code-block:: html+django
 
        <form action="" method="post">{% csrf_token %}