Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

[1.3.X] Fixed #15992 -- Added more references to settings. Thanks, aa…

…ugustin.

Backport from trunk (r16290).

git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.3.X@16291 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 879267f254946a26ebc179f3880e14a59e11e038 1 parent 7f3eda2
Jannis Leidel authored May 29, 2011

Showing 31 changed files with 215 additions and 199 deletions. Show diff stats Hide diff stats

  1. 6  docs/faq/admin.txt
  2. 15  docs/faq/models.txt
  3. 2  docs/howto/i18n.txt
  4. 6  docs/internals/deprecation.txt
  5. 2  docs/ref/contrib/admin/index.txt
  6. 2  docs/ref/contrib/gis/geoip.txt
  7. 10  docs/ref/contrib/gis/install.txt
  8. 4  docs/ref/contrib/index.txt
  9. 2  docs/ref/contrib/messages.txt
  10. 8  docs/ref/databases.txt
  11. 29  docs/ref/django-admin.txt
  12. 2  docs/ref/forms/fields.txt
  13. 18  docs/ref/generic-views.txt
  14. 157  docs/ref/settings.txt
  15. 32  docs/ref/templates/builtins.txt
  16. 4  docs/ref/utils.txt
  17. 20  docs/releases/1.0-porting-guide.txt
  18. 4  docs/releases/1.2.txt
  19. 2  docs/releases/1.3-alpha-1.txt
  20. 8  docs/releases/1.3.txt
  21. 2  docs/topics/cache.txt
  22. 4  docs/topics/email.txt
  23. 8  docs/topics/http/file-uploads.txt
  24. 20  docs/topics/http/sessions.txt
  25. 2  docs/topics/http/views.txt
  26. 21  docs/topics/i18n/deployment.txt
  27. 10  docs/topics/i18n/internationalization.txt
  28. 2  docs/topics/logging.txt
  29. 2  docs/topics/settings.txt
  30. 4  docs/topics/templates.txt
  31. 6  docs/topics/testing.txt
6  docs/faq/admin.txt
@@ -8,8 +8,8 @@ The login cookie isn't being set correctly, because the domain of the cookie
8 8
 sent out by Django doesn't match the domain in your browser. Try these two
9 9
 things:
10 10
 
11  
-    * Set the ``SESSION_COOKIE_DOMAIN`` setting in your admin config file
12  
-      to match your domain. For example, if you're going to
  11
+    * Set the :setting:`SESSION_COOKIE_DOMAIN` setting in your admin config
  12
+      file to match your domain. For example, if you're going to
13 13
       "http://www.example.com/admin/" in your browser, in
14 14
       "myproject.settings" you should set ``SESSION_COOKIE_DOMAIN = 'www.example.com'``.
15 15
 
@@ -17,7 +17,7 @@ things:
17 17
       don't have dots in them. If you're running the admin site on "localhost"
18 18
       or another domain that doesn't have a dot in it, try going to
19 19
       "localhost.localdomain" or "127.0.0.1". And set
20  
-      ``SESSION_COOKIE_DOMAIN`` accordingly.
  20
+      :setting:`SESSION_COOKIE_DOMAIN` accordingly.
21 21
 
22 22
 I can't log in. When I enter a valid username and password, it brings up the login page again, with a "Please enter a correct username and password" error.
23 23
 -----------------------------------------------------------------------------------------------------------------------------------------------------------
15  docs/faq/models.txt
@@ -6,16 +6,17 @@ FAQ: Databases and models
6 6
 How can I see the raw SQL queries Django is running?
7 7
 ----------------------------------------------------
8 8
 
9  
-Make sure your Django ``DEBUG`` setting is set to ``True``. Then, just do
10  
-this::
  9
+Make sure your Django :setting:`DEBUG` setting is set to ``True``.
  10
+Then, just do this::
11 11
 
12 12
     >>> from django.db import connection
13 13
     >>> connection.queries
14 14
     [{'sql': 'SELECT polls_polls.id,polls_polls.question,polls_polls.pub_date FROM polls_polls',
15 15
     'time': '0.002'}]
16 16
 
17  
-``connection.queries`` is only available if ``DEBUG`` is ``True``. It's a list
18  
-of dictionaries in order of query execution. Each dictionary has the following::
  17
+``connection.queries`` is only available if :setting:`DEBUG` is ``True``.
  18
+It's a list of dictionaries in order of query execution. Each dictionary has
  19
+the following::
19 20
 
20 21
     ``sql`` -- The raw SQL statement
21 22
     ``time`` -- How long the statement took to execute, in seconds.
@@ -90,13 +91,13 @@ Why is Django leaking memory?
90 91
 
91 92
 Django isn't known to leak memory. If you find your Django processes are
92 93
 allocating more and more memory, with no sign of releasing it, check to make
93  
-sure your ``DEBUG`` setting is set to ``False``. If ``DEBUG`` is ``True``, then
94  
-Django saves a copy of every SQL statement it has executed.
  94
+sure your :setting:`DEBUG` setting is set to ``False``. If :setting:`DEBUG`
  95
+is ``True``, then Django saves a copy of every SQL statement it has executed.
95 96
 
96 97
 (The queries are saved in ``django.db.connection.queries``. See
97 98
 `How can I see the raw SQL queries Django is running?`_.)
98 99
 
99  
-To fix the problem, set ``DEBUG`` to ``False``.
  100
+To fix the problem, set :setting:`DEBUG` to ``False``.
100 101
 
101 102
 If you need to clear the query list manually at any point in your functions,
102 103
 just call ``reset_queries()``, like this::
2  docs/howto/i18n.txt
@@ -55,7 +55,7 @@ message file specific to the project you are composing. The choice is yours.
55 55
 
56 56
 All message file repositories are structured the same way. They are:
57 57
 
58  
-    * All paths listed in ``LOCALE_PATHS`` in your settings file are
  58
+    * All paths listed in :setting:`LOCALE_PATHS` in your settings file are
59 59
       searched for ``<language>/LC_MESSAGES/django.(po|mo)``
60 60
     * ``$PROJECTPATH/locale/<language>/LC_MESSAGES/django.(po|mo)`` --
61 61
       deprecated, see above.
6  docs/internals/deprecation.txt
@@ -167,9 +167,9 @@ their deprecation, as per the :ref:`Django deprecation policy
167 167
           and :class:`django.contrib.auth.context_processors.PermLookupDict`,
168 168
           respectively.
169 169
 
170  
-        * The ``MEDIA_URL`` or ``STATIC_URL`` settings are required to end
171  
-          with a trailing slash to ensure there is a consistent way to
172  
-          combine paths in templates.
  170
+        * The :setting:`MEDIA_URL` or :setting:`STATIC_URL` settings are
  171
+          required to end with a trailing slash to ensure there is a consistent
  172
+          way to combine paths in templates.
173 173
 
174 174
     * 2.0
175 175
         * ``django.views.defaults.shortcut()``. This function has been moved
2  docs/ref/contrib/admin/index.txt
@@ -1624,7 +1624,7 @@ In this example, we register the default ``AdminSite`` instance
1624 1624
     )
1625 1625
 
1626 1626
 Above we used ``admin.autodiscover()`` to automatically load the
1627  
-``INSTALLED_APPS`` admin.py modules.
  1627
+:setting:`INSTALLED_APPS` admin.py modules.
1628 1628
 
1629 1629
 In this example, we register the ``AdminSite`` instance
1630 1630
 ``myproject.admin.admin_site`` at the URL ``/myadmin/`` ::
2  docs/ref/contrib/gis/geoip.txt
@@ -18,7 +18,7 @@ the GeoIP C libary and either the GeoIP `Country`__ or `City`__
18 18
 datasets in binary format (the CSV files will not work!).  These datasets may be 
19 19
 `downloaded from MaxMind`__.  Grab the ``GeoIP.dat.gz`` and ``GeoLiteCity.dat.gz``
20 20
 and unzip them in a directory corresponding to what you set 
21  
-``GEOIP_PATH`` with in your settings.  See the example and reference below
  21
+:setting:`GEOIP_PATH` with in your settings.  See the example and reference below
22 22
 for more details.
23 23
 
24 24
 __ http://www.maxmind.com/app/c
10  docs/ref/contrib/gis/install.txt
@@ -184,9 +184,9 @@ If using a binary package of GEOS (e.g., on Ubuntu), you may need to :ref:`binut
184 184
 ~~~~~~~~~~~~~~~~~~~~~
185 185
 
186 186
 If your GEOS library is in a non-standard location, or you don't want to
187  
-modify the system's library path then the :setting:`GEOS_LIBRARY_PATH`  setting
188  
-may be added to your Django settings file with the full path to the GEOS
189  
-C library.  For example::
  187
+modify the system's library path then the :setting:`GEOS_LIBRARY_PATH`
  188
+setting may be added to your Django settings file with the full path to the
  189
+GEOS C library.  For example::
190 190
 
191 191
     GEOS_LIBRARY_PATH = '/home/bob/local/lib/libgeos_c.so'
192 192
 
@@ -592,8 +592,8 @@ Now, the ``spatialite`` command can be used to initialize a spatial database::
592 592
 __ http://www.gaia-gis.it/spatialite/resources.html
593 593
 
594 594
 
595  
-Add ``django.contrib.gis`` to ``INSTALLED_APPS``
596  
-------------------------------------------------
  595
+Add ``django.contrib.gis`` to :setting:`INSTALLED_APPS`
  596
+-------------------------------------------------------
597 597
 
598 598
 Like other Django contrib applications, you will *only* need to add
599 599
 :mod:`django.contrib.gis` to :setting:`INSTALLED_APPS` in your settings.
4  docs/ref/contrib/index.txt
@@ -14,8 +14,8 @@ those packages have.
14 14
 
15 15
     For most of these add-ons -- specifically, the add-ons that include either
16 16
     models or template tags -- you'll need to add the package name (e.g.,
17  
-    ``'django.contrib.admin'``) to your ``INSTALLED_APPS`` setting and re-run
18  
-    ``manage.py syncdb``.
  17
+    ``'django.contrib.admin'``) to your :setting:`INSTALLED_APPS` setting and
  18
+    re-run ``manage.py syncdb``.
19 19
 
20 20
 .. _"batteries included" philosophy: http://docs.python.org/tutorial/stdlib.html#batteries-included
21 21
 
2  docs/ref/contrib/messages.txt
@@ -414,7 +414,7 @@ SESSION_COOKIE_DOMAIN
414 414
 Default: ``None``
415 415
 
416 416
 The storage backends that use cookies -- ``CookieStorage`` and
417  
-``FallbackStorage`` -- use the value of ``SESSION_COOKIE_DOMAIN`` in
  417
+``FallbackStorage`` -- use the value of :setting:`SESSION_COOKIE_DOMAIN` in
418 418
 setting their cookies. See the :doc:`settings documentation </ref/settings>`
419 419
 for more information on how this works and why you might need to set it.
420 420
 
8  docs/ref/databases.txt
@@ -262,8 +262,8 @@ Connection settings are used in this order:
262 262
        :setting:`HOST`, :setting:`PORT`
263 263
     3. MySQL option files.
264 264
 
265  
-In other words, if you set the name of the database in ``OPTIONS``,
266  
-this will take precedence over ``NAME``, which would override
  265
+In other words, if you set the name of the database in :setting:`OPTIONS`,
  266
+this will take precedence over :setting:`NAME`, which would override
267 267
 anything in a `MySQL option file`_.
268 268
 
269 269
 Here's a sample configuration which uses a MySQL option file::
@@ -551,7 +551,7 @@ Your Django settings.py file should look something like this for Oracle::
551 551
 
552 552
 If you don't use a ``tnsnames.ora`` file or a similar naming method that
553 553
 recognizes the SID ("xe" in this example), then fill in both
554  
-``HOST`` and ``PORT`` like so::
  554
+:setting:`HOST` and :setting:`PORT` like so::
555 555
 
556 556
     DATABASES = {
557 557
         'default': {
@@ -564,7 +564,7 @@ recognizes the SID ("xe" in this example), then fill in both
564 564
         }
565 565
     }
566 566
 
567  
-You should supply both ``HOST`` and ``PORT``, or leave both
  567
+You should supply both :setting:`HOST` and :setting:`PORT`, or leave both
568 568
 as empty strings.
569 569
 
570 570
 Threaded option
29  docs/ref/django-admin.txt
@@ -57,7 +57,7 @@ App names
57 57
 ---------
58 58
 
59 59
 Many commands take a list of "app names." An "app name" is the basename of
60  
-the package containing your models. For example, if your ``INSTALLED_APPS``
  60
+the package containing your models. For example, if your :setting:`INSTALLED_APPS`
61 61
 contains the string ``'mysite.blog'``, the app name is ``blog``.
62 62
 
63 63
 Determining the version
@@ -126,7 +126,7 @@ dbshell
126 126
 
127 127
 Runs the command-line client for the database engine specified in your
128 128
 ``ENGINE`` setting, with the connection parameters specified in your
129  
-``USER``, ``PASSWORD``, etc., settings.
  129
+:setting:`USER`, :setting:`PASSWORD`, etc., settings.
130 130
 
131 131
     * For PostgreSQL, this runs the ``psql`` command-line client.
132 132
     * For MySQL, this runs the ``mysql`` command-line client.
@@ -151,8 +151,9 @@ Displays differences between the current settings file and Django's default
151 151
 settings.
152 152
 
153 153
 Settings that don't appear in the defaults are followed by ``"###"``. For
154  
-example, the default settings don't define ``ROOT_URLCONF``, so
155  
-``ROOT_URLCONF`` is followed by ``"###"`` in the output of ``diffsettings``.
  154
+example, the default settings don't define :setting:`ROOT_URLCONF`, so
  155
+:setting:`ROOT_URLCONF` is followed by ``"###"`` in the output of
  156
+``diffsettings``.
156 157
 
157 158
 Note that Django's default settings live in ``django/conf/global_settings.py``,
158 159
 if you're ever curious to see the full list of defaults.
@@ -245,7 +246,7 @@ inspectdb
245 246
 .. django-admin:: inspectdb
246 247
 
247 248
 Introspects the database tables in the database pointed-to by the
248  
-``NAME`` setting and outputs a Django model module (a ``models.py``
  249
+:setting:`NAME` setting and outputs a Django model module (a ``models.py``
249 250
 file) to standard output.
250 251
 
251 252
 Use this if you have a legacy database with which you'd like to use Django.
@@ -309,7 +310,7 @@ fixture can be distributed over multiple directories, in multiple applications.
309 310
 Django will search in three locations for fixtures:
310 311
 
311 312
    1. In the ``fixtures`` directory of every installed application
312  
-   2. In any directory named in the ``FIXTURE_DIRS`` setting
  313
+   2. In any directory named in the :setting:`FIXTURE_DIRS` setting
313 314
    3. In the literal path named by the fixture
314 315
 
315 316
 Django will load any and all fixtures it finds in these locations that match
@@ -340,7 +341,7 @@ directories will be included in the search path. For example::
340 341
 
341 342
 would search ``<appname>/fixtures/foo/bar/mydata.json`` for each installed
342 343
 application,  ``<dirname>/foo/bar/mydata.json`` for each directory in
343  
-``FIXTURE_DIRS``, and the literal path ``foo/bar/mydata.json``.
  344
+:setting:`FIXTURE_DIRS`, and the literal path ``foo/bar/mydata.json``.
344 345
 
345 346
 When fixture files are processed, the data is saved to the database as is.
346 347
 Model defined ``save`` methods and ``pre_save`` signals are not called.
@@ -742,7 +743,7 @@ Serving static files with the development server
742 743
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
743 744
 
744 745
 By default, the development server doesn't serve any static files for your site
745  
-(such as CSS files, images, things under ``MEDIA_URL`` and so forth). If
  746
+(such as CSS files, images, things under :setting:`MEDIA_URL` and so forth). If
746 747
 you want to configure Django to serve static media, read :doc:`/howto/static-files`.
747 748
 
748 749
 shell
@@ -912,13 +913,13 @@ syncdb
912 913
 
913 914
 .. django-admin:: syncdb
914 915
 
915  
-Creates the database tables for all apps in ``INSTALLED_APPS`` whose tables
916  
-have not already been created.
  916
+Creates the database tables for all apps in :setting:`INSTALLED_APPS` whose
  917
+tables have not already been created.
917 918
 
918 919
 Use this command when you've added new applications to your project and want to
919 920
 install them in the database. This includes any apps shipped with Django that
920  
-might be in ``INSTALLED_APPS`` by default. When you start a new project, run
921  
-this command to install the default apps.
  921
+might be in :setting:`INSTALLED_APPS` by default. When you start a new project,
  922
+run this command to install the default apps.
922 923
 
923 924
 .. admonition:: Syncdb will not alter existing tables
924 925
 
@@ -1032,8 +1033,8 @@ validate
1032 1033
 
1033 1034
 .. django-admin:: validate
1034 1035
 
1035  
-Validates all installed models (according to the ``INSTALLED_APPS`` setting)
1036  
-and prints validation errors to standard output.
  1036
+Validates all installed models (according to the :setting:`INSTALLED_APPS`
  1037
+setting) and prints validation errors to standard output.
1037 1038
 
1038 1039
 Commands provided by applications
1039 1040
 =================================
2  docs/ref/forms/fields.txt
@@ -759,7 +759,7 @@ Takes the following optional arguments:
759 759
 .. attribute:: URLField.validator_user_agent
760 760
 
761 761
     String used as the user-agent used when checking for a URL's existence.
762  
-    Defaults to the value of the ``URL_VALIDATOR_USER_AGENT`` setting.
  762
+    Defaults to the value of the :setting:`URL_VALIDATOR_USER_AGENT` setting.
763 763
 
764 764
 .. versionchanged:: 1.2
765 765
    The URLField previously did not recognize URLs as valid that contained an IDN
18  docs/ref/generic-views.txt
@@ -58,7 +58,7 @@ which is a dictionary of the parameters captured in the URL.
58 58
       just before rendering the template.
59 59
 
60 60
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
61  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  61
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
62 62
 
63 63
 **Example:**
64 64
 
@@ -198,7 +198,7 @@ a date in the *future* are not included unless you set ``allow_future`` to
198 198
       the view's template.
199 199
 
200 200
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
201  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  201
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
202 202
 
203 203
     * ``allow_future``: A boolean specifying whether to include "future"
204 204
       objects on this page, where "future" means objects in which the field
@@ -290,7 +290,7 @@ to ``True``.
290 290
       this is ``False``.
291 291
 
292 292
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
293  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  293
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
294 294
 
295 295
     * ``allow_future``: A boolean specifying whether to include "future"
296 296
       objects on this page, where "future" means objects in which the field
@@ -377,7 +377,7 @@ date in the *future* are not displayed unless you set ``allow_future`` to
377 377
       determining the variable's name.
378 378
 
379 379
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
380  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  380
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
381 381
 
382 382
     * ``allow_future``: A boolean specifying whether to include "future"
383 383
       objects on this page, where "future" means objects in which the field
@@ -465,7 +465,7 @@ in the *future* are not displayed unless you set ``allow_future`` to ``True``.
465 465
       determining the variable's name.
466 466
 
467 467
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
468  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  468
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
469 469
 
470 470
     * ``allow_future``: A boolean specifying whether to include "future"
471 471
       objects on this page, where "future" means objects in which the field
@@ -550,7 +550,7 @@ you set ``allow_future`` to ``True``.
550 550
       determining the variable's name.
551 551
 
552 552
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
553  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  553
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
554 554
 
555 555
     * ``allow_future``: A boolean specifying whether to include "future"
556 556
       objects on this page, where "future" means objects in which the field
@@ -660,7 +660,7 @@ future, the view will throw a 404 error by default, unless you set
660 660
       to use in the template context. By default, this is ``'object'``.
661 661
 
662 662
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
663  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  663
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
664 664
 
665 665
     * ``allow_future``: A boolean specifying whether to include "future"
666 666
       objects on this page, where "future" means objects in which the field
@@ -738,7 +738,7 @@ A page representing a list of objects.
738 738
       determining the variable's name.
739 739
 
740 740
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
741  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  741
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
742 742
 
743 743
 **Template name:**
744 744
 
@@ -852,7 +852,7 @@ A page representing an individual object.
852 852
       to use in the template context. By default, this is ``'object'``.
853 853
 
854 854
     * ``mimetype``: The MIME type to use for the resulting document. Defaults
855  
-      to the value of the ``DEFAULT_CONTENT_TYPE`` setting.
  855
+      to the value of the :setting:`DEFAULT_CONTENT_TYPE` setting.
856 856
 
857 857
 **Template name:**
858 858
 
157  docs/ref/settings.txt
@@ -86,7 +86,7 @@ A tuple of strings representing allowed prefixes for the ``{% ssi %}`` template
86 86
 tag. This is a security measure, so that template authors can't access files
87 87
 that they shouldn't be accessing.
88 88
 
89  
-For example, if ``ALLOWED_INCLUDE_ROOTS`` is ``('/home/html', '/var/www')``,
  89
+For example, if :setting:`ALLOWED_INCLUDE_ROOTS` is ``('/home/html', '/var/www')``,
90 90
 then ``{% ssi /home/html/foo.txt %}`` would work, but ``{% ssi /etc/passwd %}``
91 91
 wouldn't.
92 92
 
@@ -102,7 +102,7 @@ in the URLconf and it doesn't end in a slash, an HTTP redirect is issued to the
102 102
 same URL with a slash appended. Note that the redirect may cause any data
103 103
 submitted in a POST request to be lost.
104 104
 
105  
-The ``APPEND_SLASH`` setting is only used if
  105
+The :setting:`APPEND_SLASH` setting is only used if
106 106
 :class:`~django.middleware.common.CommonMiddleware` is installed
107 107
 (see :doc:`/topics/http/middleware`). See also :setting:`PREPEND_WWW`.
108 108
 
@@ -602,9 +602,9 @@ locale-dictated format has higher precedence and will be applied instead. See
602 602
 :tfilter:`allowed date format strings <date>`.
603 603
 
604 604
 .. versionchanged:: 1.2
605  
-    This setting can now be overriden by setting ``USE_L10N`` to ``True``.
  605
+    This setting can now be overriden by setting :setting:`USE_L10N` to ``True``.
606 606
 
607  
-See also ``DATETIME_FORMAT``, ``TIME_FORMAT`` and ``SHORT_DATE_FORMAT``.
  607
+See also :setting:`DATETIME_FORMAT`, :setting:`TIME_FORMAT` and :setting:`SHORT_DATE_FORMAT`.
608 608
 
609 609
 .. setting:: DATE_INPUT_FORMATS
610 610
 
@@ -625,7 +625,7 @@ Note that these format strings are specified in Python's datetime_ module
625 625
 syntax, that is different from the one used by Django for formatting dates
626 626
 to be displayed.
627 627
 
628  
-See also ``DATETIME_INPUT_FORMATS`` and ``TIME_INPUT_FORMATS``.
  628
+See also :setting:`DATETIME_INPUT_FORMATS` and :setting:`TIME_INPUT_FORMATS`.
629 629
 
630 630
 .. _datetime: http://docs.python.org/library/datetime.html#strftime-strptime-behavior
631 631
 
@@ -642,9 +642,9 @@ locale-dictated format has higher precedence and will be applied instead. See
642 642
 :tfilter:`allowed date format strings <date>`.
643 643
 
644 644
 .. versionchanged:: 1.2
645  
-    This setting can now be overriden by setting ``USE_L10N`` to ``True``.
  645
+    This setting can now be overriden by setting :setting:`USE_L10N` to ``True``.
646 646
 
647  
-See also ``DATE_FORMAT``, ``TIME_FORMAT`` and ``SHORT_DATETIME_FORMAT``.
  647
+See also :setting:`DATE_FORMAT`, :setting:`TIME_FORMAT` and :setting:`SHORT_DATETIME_FORMAT`.
648 648
 
649 649
 .. setting:: DATETIME_INPUT_FORMATS
650 650
 
@@ -665,7 +665,7 @@ Note that these format strings are specified in Python's datetime_ module
665 665
 syntax, that is different from the one used by Django for formatting dates
666 666
 to be displayed.
667 667
 
668  
-See also ``DATE_INPUT_FORMATS`` and ``TIME_INPUT_FORMATS``.
  668
+See also :setting:`DATE_INPUT_FORMATS` and :setting:`TIME_INPUT_FORMATS`.
669 669
 
670 670
 .. _datetime: http://docs.python.org/library/datetime.html#strftime-strptime-behavior
671 671
 
@@ -688,11 +688,12 @@ Still, note that there are always going to be sections of your debug output that
688 688
 are inappropriate for public consumption. File paths, configuration options, and
689 689
 the like all give attackers extra information about your server.
690 690
 
691  
-It is also important to remember that when running with ``DEBUG`` turned on, Django
692  
-will remember every SQL query it executes. This is useful when you are debugging,
693  
-but on a production server, it will rapidly consume memory.
  691
+It is also important to remember that when running with :setting:`DEBUG`
  692
+turned on, Django will remember every SQL query it executes. This is useful
  693
+when you are debugging, but on a production server, it will rapidly consume
  694
+memory.
694 695
 
695  
-Never deploy a site into production with ``DEBUG`` turned on.
  696
+Never deploy a site into production with :setting:`DEBUG` turned on.
696 697
 
697 698
 .. _django/views/debug.py: http://code.djangoproject.com/browser/django/trunk/django/views/debug.py
698 699
 
@@ -725,7 +726,7 @@ DEFAULT_CHARSET
725 726
 Default: ``'utf-8'``
726 727
 
727 728
 Default charset to use for all ``HttpResponse`` objects, if a MIME type isn't
728  
-manually specified. Used with ``DEFAULT_CONTENT_TYPE`` to construct the
  729
+manually specified. Used with :setting:`DEFAULT_CONTENT_TYPE` to construct the
729 730
 ``Content-Type`` header.
730 731
 
731 732
 .. setting:: DEFAULT_CONTENT_TYPE
@@ -736,8 +737,8 @@ DEFAULT_CONTENT_TYPE
736 737
 Default: ``'text/html'``
737 738
 
738 739
 Default content type to use for all ``HttpResponse`` objects, if a MIME type
739  
-isn't manually specified. Used with ``DEFAULT_CHARSET`` to construct the
740  
-``Content-Type`` header.
  740
+isn't manually specified. Used with :setting:`DEFAULT_CHARSET` to construct
  741
+the ``Content-Type`` header.
741 742
 
742 743
 .. setting:: DEFAULT_FILE_STORAGE
743 744
 
@@ -823,7 +824,7 @@ Default: ``'localhost'``
823 824
 
824 825
 The host to use for sending e-mail.
825 826
 
826  
-See also ``EMAIL_PORT``.
  827
+See also :setting:`EMAIL_PORT`.
827 828
 
828 829
 .. setting:: EMAIL_HOST_PASSWORD
829 830
 
@@ -832,12 +833,12 @@ EMAIL_HOST_PASSWORD
832 833
 
833 834
 Default: ``''`` (Empty string)
834 835
 
835  
-Password to use for the SMTP server defined in ``EMAIL_HOST``. This setting is
836  
-used in conjunction with ``EMAIL_HOST_USER`` when authenticating to the SMTP
837  
-server. If either of these settings is empty, Django won't attempt
838  
-authentication.
  836
+Password to use for the SMTP server defined in :setting:`EMAIL_HOST`. This
  837
+setting is used in conjunction with :setting:`EMAIL_HOST_USER` when
  838
+authenticating to the SMTP server. If either of these settings is empty,
  839
+Django won't attempt authentication.
839 840
 
840  
-See also ``EMAIL_HOST_USER``.
  841
+See also :setting:`EMAIL_HOST_USER`.
841 842
 
842 843
 .. setting:: EMAIL_HOST_USER
843 844
 
@@ -846,10 +847,10 @@ EMAIL_HOST_USER
846 847
 
847 848
 Default: ``''`` (Empty string)
848 849
 
849  
-Username to use for the SMTP server defined in ``EMAIL_HOST``. If empty,
850  
-Django won't attempt authentication.
  850
+Username to use for the SMTP server defined in :setting:`EMAIL_HOST`.
  851
+If empty, Django won't attempt authentication.
851 852
 
852  
-See also ``EMAIL_HOST_PASSWORD``.
  853
+See also :setting:`EMAIL_HOST_PASSWORD`.
853 854
 
854 855
 .. setting:: EMAIL_PORT
855 856
 
@@ -858,7 +859,7 @@ EMAIL_PORT
858 859
 
859 860
 Default: ``25``
860 861
 
861  
-Port to use for the SMTP server defined in ``EMAIL_HOST``.
  862
+Port to use for the SMTP server defined in :setting:`EMAIL_HOST`.
862 863
 
863 864
 .. setting:: EMAIL_SUBJECT_PREFIX
864 865
 
@@ -1005,8 +1006,8 @@ project locales. If not ``None``, Django will check for a ``formats.py``
1005 1006
 file, under the directory named as the current locale, and will use the
1006 1007
 formats defined on this file.
1007 1008
 
1008  
-For example, if ``FORMAT_MODULE_PATH`` is set to ``mysite.formats``, and
1009  
-current language is ``en`` (English), Django will expect a directory tree
  1009
+For example, if :setting:`FORMAT_MODULE_PATH` is set to ``mysite.formats``,
  1010
+and current language is ``en`` (English), Django will expect a directory tree
1010 1011
 like::
1011 1012
 
1012 1013
     mysite/
@@ -1016,10 +1017,12 @@ like::
1016 1017
                 __init__.py
1017 1018
                 formats.py
1018 1019
 
1019  
-Available formats are ``DATE_FORMAT``, ``TIME_FORMAT``, ``DATETIME_FORMAT``,
1020  
-``YEAR_MONTH_FORMAT``, ``MONTH_DAY_FORMAT``, ``SHORT_DATE_FORMAT``,
1021  
-``SHORT_DATETIME_FORMAT``, ``FIRST_DAY_OF_WEEK``, ``DECIMAL_SEPARATOR``,
1022  
-``THOUSAND_SEPARATOR`` and ``NUMBER_GROUPING``.
  1020
+Available formats are :setting:`DATE_FORMAT`, :setting:`TIME_FORMAT`,
  1021
+:setting:`DATETIME_FORMAT`, :setting:`YEAR_MONTH_FORMAT`,
  1022
+:setting:`MONTH_DAY_FORMAT`, :setting:`SHORT_DATE_FORMAT`,
  1023
+:setting:`SHORT_DATETIME_FORMAT`, :setting:`FIRST_DAY_OF_WEEK`,
  1024
+:setting:`DECIMAL_SEPARATOR`, :setting:`THOUSAND_SEPARATOR` and
  1025
+:setting:`NUMBER_GROUPING`.
1023 1026
 
1024 1027
 .. setting:: IGNORABLE_404_ENDS
1025 1028
 
@@ -1070,7 +1073,7 @@ Default: ``()`` (Empty tuple)
1070 1073
 
1071 1074
 A tuple of IP addresses, as strings, that:
1072 1075
 
1073  
-    * See debug comments, when ``DEBUG`` is ``True``
  1076
+    * See debug comments, when :setting:`DEBUG` is ``True``
1074 1077
     * Receive X headers if the ``XViewMiddleware`` is installed (see
1075 1078
       :doc:`/topics/http/middleware`)
1076 1079
 
@@ -1092,8 +1095,8 @@ LANGUAGE_COOKIE_NAME
1092 1095
 
1093 1096
 Default: ``'django_language'``
1094 1097
 
1095  
-The name of the cookie to use for the language cookie. This can be whatever you
1096  
-want (but should be different from ``SESSION_COOKIE_NAME``). See
  1098
+The name of the cookie to use for the language cookie. This can be whatever
  1099
+you want (but should be different from :setting:`SESSION_COOKIE_NAME`). See
1097 1100
 :doc:`/topics/i18n/index`.
1098 1101
 
1099 1102
 .. setting:: LANGUAGES
@@ -1117,12 +1120,13 @@ This specifies which languages are available for language selection. See
1117 1120
 Generally, the default value should suffice. Only set this setting if you want
1118 1121
 to restrict language selection to a subset of the Django-provided languages.
1119 1122
 
1120  
-If you define a custom ``LANGUAGES`` setting, it's OK to mark the languages as
1121  
-translation strings (as in the default value referred to above) -- but use a
1122  
-"dummy" ``gettext()`` function, not the one in ``django.utils.translation``.
1123  
-You should *never* import ``django.utils.translation`` from within your
1124  
-settings file, because that module in itself depends on the settings, and that
1125  
-would cause a circular import.
  1123
+If you define a custom :setting:`LANGUAGES` setting, it's OK to mark the
  1124
+languages as translation strings (as in the default value referred to above)
  1125
+-- but use a "dummy" ``gettext()`` function, not the one in
  1126
+``django.utils.translation``. You should *never* import
  1127
+``django.utils.translation`` from within your settings file, because that
  1128
+module in itself depends on the settings, and that would cause a circular
  1129
+import.
1126 1130
 
1127 1131
 The solution is to use a "dummy" ``gettext()`` function. Here's a sample
1128 1132
 settings file::
@@ -1137,7 +1141,7 @@ settings file::
1137 1141
 With this arrangement, ``django-admin.py makemessages`` will still find and
1138 1142
 mark these strings for translation, but the translation won't happen at
1139 1143
 runtime -- so you'll have to remember to wrap the languages in the *real*
1140  
-``gettext()`` in any code that uses ``LANGUAGES`` at runtime.
  1144
+``gettext()`` in any code that uses :setting:`LANGUAGES` at runtime.
1141 1145
 
1142 1146
 .. setting:: LOCALE_PATHS
1143 1147
 
@@ -1233,7 +1237,7 @@ MANAGERS
1233 1237
 
1234 1238
 Default: ``()`` (Empty tuple)
1235 1239
 
1236  
-A tuple in the same format as ``ADMINS`` that specifies who should get
  1240
+A tuple in the same format as :setting:`ADMINS` that specifies who should get
1237 1241
 broken-link notifications when ``SEND_BROKEN_LINK_EMAILS=True``.
1238 1242
 
1239 1243
 .. setting:: MEDIA_ROOT
@@ -1338,8 +1342,9 @@ drilldown, the header for a given day displays the day and month. Different
1338 1342
 locales have different formats. For example, U.S. English would say
1339 1343
 "January 1," whereas Spanish might say "1 Enero."
1340 1344
 
1341  
-See :tfilter:`allowed date format strings <date>`. See also ``DATE_FORMAT``,
1342  
-``DATETIME_FORMAT``, ``TIME_FORMAT`` and ``YEAR_MONTH_FORMAT``.
  1345
+See :tfilter:`allowed date format strings <date>`. See also
  1346
+:setting:`DATE_FORMAT`, :setting:`DATETIME_FORMAT`,
  1347
+:setting:`TIME_FORMAT` and :setting:`YEAR_MONTH_FORMAT`.
1343 1348
 
1344 1349
 .. setting:: NUMBER_GROUPING
1345 1350
 
@@ -1433,11 +1438,11 @@ SEND_BROKEN_LINK_EMAILS
1433 1438
 
1434 1439
 Default: ``False``
1435 1440
 
1436  
-Whether to send an e-mail to the ``MANAGERS`` each time somebody visits a
1437  
-Django-powered page that is 404ed with a non-empty referer (i.e., a broken
  1441
+Whether to send an e-mail to the :setting:`MANAGERS` each time somebody visits
  1442
+a Django-powered page that is 404ed with a non-empty referer (i.e., a broken
1438 1443
 link). This is only used if ``CommonMiddleware`` is installed (see
1439  
-:doc:`/topics/http/middleware`. See also ``IGNORABLE_404_STARTS``,
1440  
-``IGNORABLE_404_ENDS`` and :doc:`/howto/error-reporting`.
  1444
+:doc:`/topics/http/middleware`. See also :setting:`IGNORABLE_404_STARTS`,
  1445
+:setting:`IGNORABLE_404_ENDS` and :doc:`/howto/error-reporting`.
1441 1446
 
1442 1447
 .. setting:: SERIALIZATION_MODULES
1443 1448
 
@@ -1460,7 +1465,7 @@ SERVER_EMAIL
1460 1465
 Default: ``'root@localhost'``
1461 1466
 
1462 1467
 The e-mail address that error messages come from, such as those sent to
1463  
-``ADMINS`` and ``MANAGERS``.
  1468
+:setting:`ADMINS` and :setting:`MANAGERS`.
1464 1469
 
1465 1470
 .. setting:: SESSION_COOKIE_AGE
1466 1471
 
@@ -1509,7 +1514,8 @@ SESSION_COOKIE_NAME
1509 1514
 Default: ``'sessionid'``
1510 1515
 
1511 1516
 The name of the cookie to use for sessions. This can be whatever you want (but
1512  
-should be different from ``LANGUAGE_COOKIE_NAME``). See the :doc:`/topics/http/sessions`.
  1517
+should be different from :setting:`LANGUAGE_COOKIE_NAME`).
  1518
+See the :doc:`/topics/http/sessions`.
1513 1519
 
1514 1520
 .. setting:: SESSION_COOKIE_PATH
1515 1521
 
@@ -1599,7 +1605,7 @@ templates. Note that if :setting:`USE_L10N` is set to ``True``, then the
1599 1605
 corresponding locale-dictated format has higher precedence and will be applied.
1600 1606
 See :tfilter:`allowed date format strings <date>`.
1601 1607
 
1602  
-See also ``DATE_FORMAT`` and ``SHORT_DATETIME_FORMAT``.
  1608
+See also :setting:`DATE_FORMAT` and :setting:`SHORT_DATETIME_FORMAT`.
1603 1609
 
1604 1610
 .. setting:: SHORT_DATETIME_FORMAT
1605 1611
 
@@ -1615,7 +1621,7 @@ templates. Note that if :setting:`USE_L10N` is set to ``True``, then the
1615 1621
 corresponding locale-dictated format has higher precedence and will be applied.
1616 1622
 See :tfilter:`allowed date format strings <date>`.
1617 1623
 
1618  
-See also ``DATE_FORMAT`` and ``SHORT_DATETIME_FORMAT``.
  1624
+See also :setting:`DATE_FORMAT` and :setting:`SHORT_DATETIME_FORMAT`.
1619 1625
 
1620 1626
 .. setting:: SITE_ID
1621 1627
 
@@ -1724,10 +1730,10 @@ error page will display a detailed report for any ``TemplateSyntaxError``. This
1724 1730
 report contains the relevant snippet of the template, with the appropriate line
1725 1731
 highlighted.
1726 1732
 
1727  
-Note that Django only displays fancy error pages if ``DEBUG`` is ``True``, so
  1733
+Note that Django only displays fancy error pages if :setting:`DEBUG` is ``True``, so
1728 1734
 you'll want to set that to take advantage of this setting.
1729 1735
 
1730  
-See also ``DEBUG``.
  1736
+See also :setting:`DEBUG`.
1731 1737
 
1732 1738
 .. setting:: TEMPLATE_DIRS
1733 1739
 
@@ -1759,9 +1765,9 @@ module, subsequent items are passed to the ``Loader`` during initialization. See
1759 1765
 
1760 1766
 .. versionchanged:: 1.2
1761 1767
     The class-based API for template loaders was introduced in Django 1.2
1762  
-    although  the ``TEMPLATE_LOADERS`` setting will accept strings that specify
1763  
-    function-based loaders until compatibility with them is completely removed in
1764  
-    Django 1.4.
  1768
+    although  the :setting:`TEMPLATE_LOADERS` setting will accept strings
  1769
+    that specify function-based loaders until compatibility with them is
  1770
+    completely removed in Django 1.4.
1765 1771
 
1766 1772
 .. setting:: TEMPLATE_STRING_IF_INVALID
1767 1773
 
@@ -1795,10 +1801,11 @@ THOUSAND_SEPARATOR
1795 1801
 
1796 1802
 .. versionadded:: 1.2
1797 1803
 
1798  
-Default ``,`` (Comma)
  1804
+Default: ``,`` (Comma)
1799 1805
 
1800 1806
 Default thousand separator used when formatting numbers. This setting is
1801  
-used only when ``NUMBER_GROUPING`` and ``USE_THOUSAND_SEPARATOR`` are set.
  1807
+used only when :setting:`NUMBER_GROUPING` and :setting:`USE_THOUSAND_SEPARATOR`
  1808
+are set.
1802 1809
 
1803 1810
 See also :setting:`NUMBER_GROUPING`, :setting:`DECIMAL_SEPARATOR` and
1804 1811
 :setting:`USE_THOUSAND_SEPARATOR`.
@@ -1816,9 +1823,9 @@ locale-dictated format has higher precedence and will be applied instead. See
1816 1823
 :tfilter:`allowed date format strings <date>`.
1817 1824
 
1818 1825
 .. versionchanged:: 1.2
1819  
-    This setting can now be overriden by setting ``USE_L10N`` to ``True``.
  1826
+    This setting can now be overriden by setting :setting:`USE_L10N` to ``True``.
1820 1827
 
1821  
-See also ``DATE_FORMAT`` and ``DATETIME_FORMAT``.
  1828
+See also :setting:`DATE_FORMAT` and :setting:`DATETIME_FORMAT`.
1822 1829
 
1823 1830
 .. setting:: TIME_INPUT_FORMATS
1824 1831
 
@@ -1835,7 +1842,7 @@ Note that these format strings are specified in Python's datetime_ module
1835 1842
 syntax, that is different from the one used by Django for formatting dates
1836 1843
 to be displayed.
1837 1844
 
1838  
-See also ``DATE_INPUT_FORMATS`` and ``DATETIME_INPUT_FORMATS``.
  1845
+See also :setting:`DATE_INPUT_FORMATS` and :setting:`DATETIME_INPUT_FORMATS`.
1839 1846
 
1840 1847
 .. _datetime: http://docs.python.org/library/datetime.html#strftime-strptime-behavior
1841 1848
 
@@ -1854,7 +1861,7 @@ A string representing the time zone for this installation, or
1854 1861
 choices lists more than one on the same line; you'll want to use just
1855 1862
 one of the choices for a given time zone. For instance, one line says
1856 1863
 ``'Europe/London GB GB-Eire'``, but you should use the first bit of
1857  
-that -- ``'Europe/London'`` -- as your ``TIME_ZONE`` setting.)
  1864
+that -- ``'Europe/London'`` -- as your :setting:`TIME_ZONE` setting.)
1858 1865
 
1859 1866
 Note that this is the time zone to which Django will convert all
1860 1867
 dates/times -- not necessarily the timezone of the server. For
@@ -1862,7 +1869,7 @@ example, one server may serve multiple Django-powered sites, each with
1862 1869
 a separate time-zone setting.
1863 1870
 
1864 1871
 Normally, Django sets the ``os.environ['TZ']`` variable to the time
1865  
-zone you specify in the ``TIME_ZONE`` setting. Thus, all your views
  1872
+zone you specify in the :setting:`TIME_ZONE` setting. Thus, all your views
1866 1873
 and models will automatically operate in the correct time zone.
1867 1874
 However, Django won't set the ``TZ`` environment variable under the
1868 1875
 following conditions:
@@ -1919,7 +1926,7 @@ enabled. This provides an easy way to turn it off, for performance. If this is
1919 1926
 set to ``False``, Django will make some optimizations so as not to load the
1920 1927
 internationalization machinery.
1921 1928
 
1922  
-See also ``USE_L10N``
  1929
+See also :setting:`USE_L10N`
1923 1930
 
1924 1931
 .. setting:: USE_L10N
1925 1932
 
@@ -1928,13 +1935,13 @@ USE_L10N
1928 1935
 
1929 1936
 .. versionadded:: 1.2
1930 1937
 
1931  
-Default ``False``
  1938
+Default: ``False``
1932 1939
 
1933 1940
 A boolean that specifies if data will be localized by default or not. If this
1934 1941
 is set to ``True``, e.g. Django will display numbers and dates using the
1935 1942
 format of the current locale.
1936 1943
 
1937  
-See also ``USE_I18N`` and ``LANGUAGE_CODE``
  1944
+See also :setting:`USE_I18N` and :setting:`LANGUAGE_CODE`
1938 1945
 
1939 1946
 .. setting:: USE_THOUSAND_SEPARATOR
1940 1947
 
@@ -1943,14 +1950,15 @@ USE_THOUSAND_SEPARATOR
1943 1950
 
1944 1951
 .. versionadded:: 1.2
1945 1952
 
1946  
-Default ``False``
  1953
+Default: ``False``
1947 1954
 
1948 1955
 A boolean that specifies wheter to display numbers using a thousand separator.
1949  
-If this is set to ``True``, Django will use values from ``THOUSAND_SEPARATOR``
1950  
-and ``NUMBER_GROUPING`` from current locale, to format the number.
1951  
-``USE_L10N`` must be set to ``True``, in order to format numbers.
  1956
+If this is set to ``True``, Django will use values from
  1957
+:setting:`THOUSAND_SEPARATOR` and :setting:`NUMBER_GROUPING` from current
  1958
+locale, to format the number. :setting:`USE_L10N` must be set to ``True``,
  1959
+in order to format numbers.
1952 1960
 
1953  
-See also ``THOUSAND_SEPARATOR`` and ``NUMBER_GROUPING``.
  1961
+See also :setting:`THOUSAND_SEPARATOR` and :setting:`NUMBER_GROUPING`.
1954 1962
 
1955 1963
 .. setting:: YEAR_MONTH_FORMAT
1956 1964
 
@@ -1968,8 +1976,9 @@ drilldown, the header for a given month displays the month and the year.
1968 1976
 Different locales have different formats. For example, U.S. English would say
1969 1977
 "January 2006," whereas another locale might say "2006/January."
1970 1978
 
1971  
-See :tfilter:`allowed date format strings <date>`. See also ``DATE_FORMAT``,
1972  
-``DATETIME_FORMAT``, ``TIME_FORMAT`` and ``MONTH_DAY_FORMAT``.
  1979
+See :tfilter:`allowed date format strings <date>`. See also
  1980
+:setting:`DATE_FORMAT`, :setting:`DATETIME_FORMAT`, :setting:`TIME_FORMAT`
  1981
+and :setting:`MONTH_DAY_FORMAT`.
1973 1982
 
1974 1983
 Deprecated settings
1975 1984
 ===================
32  docs/ref/templates/builtins.txt
@@ -1295,10 +1295,11 @@ If ``value`` is a ``datetime`` object (e.g., the result of
1295 1295
 ``datetime.datetime.now()``), the output will be the string
1296 1296
 ``'Wed 09 Jan 2008'``.
1297 1297
 
1298  
-The format passed can be one of the predefined ones ``DATE_FORMAT``,
1299  
-``DATETIME_FORMAT``, ``SHORT_DATE_FORMAT`` or ``SHORT_DATETIME_FORMAT``, or a
1300  
-custom format that uses the format specifiers shown in the table above. Note
1301  
-that predefined formats may vary depending on the current locale.
  1298
+The format passed can be one of the predefined ones :setting:`DATE_FORMAT`,
  1299
+:setting:`DATETIME_FORMAT`, :setting:`SHORT_DATE_FORMAT` or
  1300
+:setting:`SHORT_DATETIME_FORMAT`, or a custom format that uses the format
  1301
+specifiers shown in the table above. Note that predefined formats may vary
  1302
+depending on the current locale.
1302 1303
 
1303 1304
 Assuming that :setting:`USE_L10N` is ``True`` and :setting:`LANGUAGE_CODE` is,
1304 1305
 for example, ``"es"``, then for::
@@ -1929,9 +1930,9 @@ time
1929 1930
 
1930 1931
 Formats a time according to the given format.
1931 1932
 
1932  
-Given format can be the predefined one ``TIME_FORMAT``, or a custom format,
1933  
-same as the :tfilter:`date` filter. Note that the predefined format is locale-
1934  
-dependant.
  1933
+Given format can be the predefined one :setting:`TIME_FORMAT`, or a custom
  1934
+format, same as the :tfilter:`date` filter. Note that the predefined format
  1935
+is locale-dependant.
1935 1936
 
1936 1937
 The time filter will only accept parameters in the format string that relate
1937 1938
 to the time of day, not the date (for obvious reasons). If you need to
@@ -2231,7 +2232,7 @@ Other tags and filter libraries
2231 2232
 -------------------------------
2232 2233
 
2233 2234
 Django comes with a couple of other template-tag libraries that you have to
2234  
-enable explicitly in your ``INSTALLED_APPS`` setting and enable in your
  2235
+enable explicitly in your :setting:`INSTALLED_APPS` setting and enable in your
2235 2236
 template with the ``{% load %}`` tag.
2236 2237
 
2237 2238
 django.contrib.humanize
@@ -2262,15 +2263,18 @@ i18n
2262 2263
 
2263 2264
 Provides a couple of templatetags that allow specifying translatable text in
2264 2265
 Django templates. It is slightly different from the libraries described
2265  
-above because you don't need to add any application to the ``INSTALLED_APPS``
2266  
-setting but rather set :setting:`USE_I18N` to True, then loading it with
2267  
-``{% load i18n %}``. See :ref:`specifying-translation-strings-in-template-code`.
  2266
+above because you don't need to add any application to the
  2267
+:setting:`INSTALLED_APPS` setting but rather set :setting:`USE_I18N` to True,
  2268
+then loading it with ``{% load i18n %}``.
  2269
+
  2270
+See :ref:`specifying-translation-strings-in-template-code`.
2268 2271
 
2269 2272
 l10n
2270 2273
 ~~~~
2271 2274
 
2272 2275
 Provides a couple of templatetags that allow control over the localization of
2273 2276
 values in Django templates. It is slightly different from the libraries described
2274  
-above because you don't need to add any application to the ``INSTALLED_APPS``;
2275  
-you only need to load the library using ``{% load l10n %}``. See
2276  
-:ref:`topic-l10n-templates`.
  2277
+above because you don't need to add any application to the :setting:`INSTALLED_APPS`;
  2278
+you only need to load the library using ``{% load l10n %}``.
  2279
+
  2280
+See :ref:`topic-l10n-templates`.
4  docs/ref/utils.txt
@@ -61,8 +61,8 @@ to distinguish caches by the ``Accept-language`` header.
61 61
 
62 62
     Each header is only added if it isn't already set.
63 63
 
64  
-    ``cache_timeout`` is in seconds. The ``CACHE_MIDDLEWARE_SECONDS`` setting
65  
-    is used by default.
  64
+    ``cache_timeout`` is in seconds. The :setting:`CACHE_MIDDLEWARE_SECONDS`
  65
+    setting is used by default.
66 66
 
67 67
 .. function:: add_never_cache_headers(response)
68 68
 
20  docs/releases/1.0-porting-guide.txt
@@ -443,10 +443,10 @@ The old :exc:`EnvironmentError` has split into an :exc:`ImportError` when
443 443
 Django fails to find the settings module and a :exc:`RuntimeError` when you try
444 444
 to reconfigure settings after having already used them
445 445
 
446  
-``LOGIN_URL`` has moved
447  
-~~~~~~~~~~~~~~~~~~~~~~~
  446
+:setting:`LOGIN_URL` has moved
  447
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
448 448
 
449  
-The ``LOGIN_URL`` constant moved from ``django.contrib.auth`` into the
  449
+The :setting:`LOGIN_URL` constant moved from ``django.contrib.auth`` into the
450 450
 ``settings`` module. Instead of using ``from django.contrib.auth import
451 451
 LOGIN_URL`` refer to :setting:`settings.LOGIN_URL <LOGIN_URL>`.
452 452
 
@@ -454,11 +454,11 @@ LOGIN_URL`` refer to :setting:`settings.LOGIN_URL <LOGIN_URL>`.
454 454
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
455 455
 
456 456
 In 0.96, if a URL didn't end in a slash or have a period in the final
457  
-component of its path, and ``APPEND_SLASH`` was True, Django would redirect
458  
-to the same URL, but with a slash appended to the end. Now, Django checks to
459  
-see whether the pattern without the trailing slash would be matched by
460  
-something in your URL patterns. If so, no redirection takes place, because it
461  
-is assumed you deliberately wanted to catch that pattern.
  457
+component of its path, and :setting:`APPEND_SLASH` was True, Django would
  458
+redirect to the same URL, but with a slash appended to the end. Now, Django
  459
+checks to see whether the pattern without the trailing slash would be matched
  460
+by something in your URL patterns. If so, no redirection takes place, because
  461
+it is assumed you deliberately wanted to catch that pattern.
462 462
 
463 463
 For most people, this won't require any changes. Some people, though, have URL
464 464
 patterns that look like this::
@@ -548,8 +548,8 @@ need to reload your data. Do this after you have made the change to using
548 548
   **Back up your database first!**
549 549
 
550 550
   For SQLite, this means making a copy of the single file that stores the
551  
-  database (the name of that file is the ``DATABASE_NAME`` in your settings.py
552  
-  file).
  551
+  database (the name of that file is the :setting:`DATABASE_NAME` in your
  552
+  settings.py file).
553 553
 
554 554
 To upgrade each application to use a ``DecimalField``, you can do the
555 555
 following, replacing ``<app>`` in the code below with each app's name:
4  docs/releases/1.2.txt
@@ -1067,8 +1067,8 @@ Up to version 1.1 Django used :ref:`technical message IDs<technical-messages>`
1067 1067
 to provide localizers the possibility to translate date and time formats. They
1068 1068
 were translatable :term:`translation strings <translation string>` that could
1069 1069
 be recognized because they were all upper case (for example
1070  
-``DATETIME_FORMAT``, ``DATE_FORMAT``, ``TIME_FORMAT``). They have been
1071  
-deprecated in favor of the new :ref:`Format localization
  1070
+:setting:`DATETIME_FORMAT`, :setting:`DATE_FORMAT`, :setting:`TIME_FORMAT`).
  1071
+They have been deprecated in favor of the new :ref:`Format localization
1072 1072
 <format-localization>` infrastructure that allows localizers to specify that
1073 1073
 information in a ``formats.py`` file in the corresponding
1074 1074
 ``django/conf/locale/<locale name>/`` directory.
2  docs/releases/1.3-alpha-1.txt
@@ -249,7 +249,7 @@ framework, we have "fixed" the problem by making the list of
249 249
 prohibited words an empty list.
250 250
 
251 251
 If you want to restore the old behavior, simply put a
252  
-``PROFANITIES_LIST`` setting in your settings file that includes the
  252
+:setting:`PROFANITIES_LIST` setting in your settings file that includes the
253 253
 words that you want to prohibit (see the `commit that implemented this
254 254
 change`_ if you want to see the list of words that was historically
255 255
 prohibited). However, if avoiding profanities is important to you, you
8  docs/releases/1.3.txt
@@ -264,8 +264,8 @@ The GeoDjango test suite is now included when
264 264
 :ref:`running the Django test suite <running-unit-tests>` with ``runtests.py``
265 265
 when using :ref:`spatial database backends <spatial-backends>`.
266 266
 
267  
-``MEDIA_URL`` and ``STATIC_URL`` must end in a slash
268  
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  267
+:setting:`MEDIA_URL` and :setting:`STATIC_URL` must end in a slash
  268
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
269 269
 
270 270
 Previously, the :setting:`MEDIA_URL` setting only required a trailing slash if
271 271
 it contained a suffix beyond the domain name.
@@ -581,7 +581,7 @@ gettext domain):
581 581
 
582 582
  * Now it is possible to override the translations shipped with applications by
583 583
    using the :setting:`LOCALE_PATHS` setting whose translations have now higher
584  
-   precedence than the translations of ``INSTALLED_APPS`` applications.
  584
+   precedence than the translations of :setting:`INSTALLED_APPS` applications.
585 585
    The relative priority among the values listed in this setting has also been
586 586
    modified so the paths listed first have higher precedence than the
587 587
    ones listed later.
@@ -589,7 +589,7 @@ gettext domain):
589 589
  * The ``locale`` subdirectory of the directory containing the settings, that
590 590
    usually coincides with and is know as the *project directory* is being
591 591
    deprecated in this release as a source of translations. (the precedence of
592  
-   these translations is intermediate between applications and ``LOCALE_PATHS``
  592
+   these translations is intermediate between applications and :setting:`LOCALE_PATHS`
593 593
    translations). See the `corresponding deprecated features section`_
594 594
    of this document.
595 595
 
2  docs/topics/cache.txt
@@ -420,7 +420,7 @@ Once the cache is set up, the simplest way to use caching is to cache your
420 420
 entire site. You'll need to add
421 421
 ``'django.middleware.cache.UpdateCacheMiddleware'`` and
422 422
 ``'django.middleware.cache.FetchFromCacheMiddleware'`` to your
423  
-``MIDDLEWARE_CLASSES`` setting, as in this example::
  423
+:setting:`MIDDLEWARE_CLASSES` setting, as in this example::
424 424
 
425 425
     MIDDLEWARE_CLASSES = (
426 426
         'django.middleware.cache.UpdateCacheMiddleware',
4  docs/topics/email.txt
@@ -509,8 +509,8 @@ Defining a custom e-mail backend
509 509
 --------------------------------
510 510
 
511 511
 If you need to change how e-mails are sent you can write your own e-mail
512  
-backend. The ``EMAIL_BACKEND`` setting in your settings file is then the
513  
-Python import path for your backend class.
  512
+backend. The :setting:`EMAIL_BACKEND` setting in your settings file is then
  513
+the Python import path for your backend class.
514 514
 
515 515
 Custom e-mail backends should subclass ``BaseEmailBackend`` that is located in
516 516
 the ``django.core.mail.backends.base`` module. A custom e-mail backend must
8  docs/topics/http/file-uploads.txt
@@ -225,8 +225,8 @@ Upload Handlers
225 225
 
226 226
 When a user uploads a file, Django passes off the file data to an *upload
227 227
 handler* -- a small class that handles file data as it gets uploaded. Upload
228  
-handlers are initially defined in the ``FILE_UPLOAD_HANDLERS`` setting, which
229  
-defaults to::
  228
+handlers are initially defined in the :setting:`FILE_UPLOAD_HANDLERS` setting,
  229
+which defaults to::
230 230
 
231 231
     ("django.core.files.uploadhandler.MemoryFileUploadHandler",
232 232
      "django.core.files.uploadhandler.TemporaryFileUploadHandler",)
@@ -246,8 +246,8 @@ Modifying upload handlers on the fly
246 246
 Sometimes particular views require different upload behavior. In these cases,
247 247
 you can override upload handlers on a per-request basis by modifying
248 248
 ``request.upload_handlers``. By default, this list will contain the upload
249  
-handlers given by ``FILE_UPLOAD_HANDLERS``, but you can modify the list as you
250  
-would any other list.
  249
+handlers given by :setting:`FILE_UPLOAD_HANDLERS`, but you can modify the list
  250
+as you would any other list.
251 251
 
252 252
 For instance, suppose you've written a ``ProgressBarUploadHandler`` that
253 253
 provides feedback on upload progress to some sort of AJAX widget. You'd add this
20  docs/topics/http/sessions.txt
@@ -23,7 +23,7 @@ To enable session functionality, do the following:
23 23
       has ``SessionMiddleware`` activated.
24 24
 
25 25
 If you don't want to use sessions, you might as well remove the
26  
-``SessionMiddleware`` line from ``MIDDLEWARE_CLASSES`` and
  26
+``SessionMiddleware`` line from :setting:`MIDDLEWARE_CLASSES` and
27 27
 ``'django.contrib.sessions'`` from your :setting:`INSTALLED_APPS`.
28 28
 It'll save you a small bit of overhead.
29 29
 
@@ -39,7 +39,7 @@ Using database-backed sessions
39 39
 ------------------------------
40 40
 
41 41
 If you want to use a database-backed session, you need to add
42  
-``'django.contrib.sessions'`` to your ``INSTALLED_APPS`` setting.
  42
+``'django.contrib.sessions'`` to your :setting:`INSTALLED_APPS` setting.
43 43
 
44 44
 Once you have configured your installation, run ``manage.py syncdb``
45 45
 to install the single database table that stores session data.
@@ -359,8 +359,8 @@ setting to ``True``. When set to ``True``, Django will save the session to the
359 359
 database on every single request.
360 360
 
361 361
 Note that the session cookie is only sent when a session has been created or
362  
-modified. If ``SESSION_SAVE_EVERY_REQUEST`` is ``True``, the session cookie
363  
-will be sent on every request.
  362
+modified. If :setting:`SESSION_SAVE_EVERY_REQUEST` is ``True``, the session
  363
+cookie will be sent on every request.
364 364
 
365 365
 Similarly, the ``expires`` part of a session cookie is updated each time the
366 366
 session cookie is sent.
@@ -372,15 +372,15 @@ You can control whether the session framework uses browser-length sessions vs.
372 372
 persistent sessions with the :setting:`SESSION_EXPIRE_AT_BROWSER_CLOSE`
373 373
 setting.
374 374
 
375  
-By default, ``SESSION_EXPIRE_AT_BROWSER_CLOSE`` is set to ``False``, which
376  
-means session cookies will be stored in users' browsers for as long as
  375
+By default, :setting:`SESSION_EXPIRE_AT_BROWSER_CLOSE` is set to ``False``,
  376
+which means session cookies will be stored in users' browsers for as long as
377 377
 :setting:`SESSION_COOKIE_AGE`. Use this if you don't want people to have to
378 378
 log in every time they open a browser.
379 379
 
380  
-If ``SESSION_EXPIRE_AT_BROWSER_CLOSE`` is set to ``True``, Django will use
381  
-browser-length cookies -- cookies that expire as soon as the user closes his or
382  
-her browser. Use this if you want people to have to log in every time they open
383  
-a browser.
  380
+If :setting:`SESSION_EXPIRE_AT_BROWSER_CLOSE` is set to ``True``, Django will
  381
+use browser-length cookies -- cookies that expire as soon as the user closes
  382
+his or her browser. Use this if you want people to have to log in every time
  383
+they open a browser.
384 384
 
385 385
 This setting is a global default and can be overwritten at a per-session level
386 386
 by explicitly calling the :meth:`~backends.base.SessionBase.set_expiry` method
2  docs/topics/http/views.txt
@@ -48,7 +48,7 @@ Let's step through this code one line at a time:
48 48
 
49 49
 .. admonition:: Django's Time Zone
50 50
 
51  
-    Django includes a ``TIME_ZONE`` setting that defaults to
  51
+    Django includes a :setting:`TIME_ZONE` setting that defaults to
52 52
     ``America/Chicago``. This probably isn't where you live, so you might want
53 53
     to change it in your settings file.
54 54
 
21  docs/topics/i18n/deployment.txt
@@ -13,7 +13,7 @@ use internationalization, you should take the two seconds to set
13 13
 optimizations so as not to load the internationalization machinery.
14 14
 
15 15
 You'll probably also want to remove ``'django.core.context_processors.i18n'``
16  
-from your ``TEMPLATE_CONTEXT_PROCESSORS`` setting.
  16
+from your :setting:`TEMPLATE_CONTEXT_PROCESSORS` setting.
17 17
 
18 18
 .. note::
19 19
 
@@ -47,22 +47,22 @@ Django uses this language as the default translation -- the final attempt if no
47 47
 other translator finds a translation.
48 48
 
49 49
 If all you want to do is run Django with your native language, and a language
50  
-file is available for it, all you need to do is set ``LANGUAGE_CODE``.
  50
+file is available for it, all you need to do is set :setting:`LANGUAGE_CODE`.
51 51