summaryrefslogtreecommitdiff
path: root/docs/ref/forms
diff options
context:
space:
mode:
authorWindson yang <wiwindson@outlook.com>2017-06-06 05:26:49 +0800
committerTim Graham <timograham@gmail.com>2017-06-05 17:27:05 -0400
commitb373812b0bb4654e049ccf6a60e92a7e9f603a99 (patch)
tree9bc7ccf45e82cacc4195264002700b58084643d9 /docs/ref/forms
parent834d57b4de80e525195128c88592e0e076708a23 (diff)
[1.11.x] Fixed #28102 -- Doc'd how to compute path to built-in widget template directories.
Backport of 7f238097c0614707d6ee3fffbaf76f111b2fd38d from master
Diffstat (limited to 'docs/ref/forms')
-rw-r--r--docs/ref/forms/renderers.txt8
1 files changed, 5 insertions, 3 deletions
diff --git a/docs/ref/forms/renderers.txt b/docs/ref/forms/renderers.txt
index c94b5ef226..fcf025a9c8 100644
--- a/docs/ref/forms/renderers.txt
+++ b/docs/ref/forms/renderers.txt
@@ -93,9 +93,11 @@ Using this renderer along with the built-in widget templates requires either:
#. ``'django.forms'`` in :setting:`INSTALLED_APPS` and at least one engine
with :setting:`APP_DIRS=True <TEMPLATES-APP_DIRS>`.
-#. Adding the built-in widgets templates directory (``django/forms/templates``
- or ``django/forms/jinja2``) in :setting:`DIRS <TEMPLATES-DIRS>` of one of
- your template engines.
+#. Adding the built-in widgets templates directory in :setting:`DIRS
+ <TEMPLATES-DIRS>` of one of your template engines. To generate that path::
+
+ import django
+ django.__path__[0] + '/forms/templates' # or '/forms/jinja2'
Using this renderer requires you to make sure the form templates your project
needs can be located.