summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorJannis Leidel <jannis@leidel.info>2011-05-07 16:58:45 +0000
committerJannis Leidel <jannis@leidel.info>2011-05-07 16:58:45 +0000
commit0322f2b6533852b51d83ac4d55f11d75cc0f41b0 (patch)
tree2d9764785c3fdb9e3723bea8ccf8030abd4d5485 /docs
parent032b4ab5dfc39b8166d472ae5e360f985afe2988 (diff)
Fixed #15263 -- Added support for format localization to the now template tag. Thanks to danielr and dmclain.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16172 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs')
-rw-r--r--docs/ref/templates/builtins.txt12
1 files changed, 12 insertions, 0 deletions
diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt
index 1767b5ba07..29bed25db9 100644
--- a/docs/ref/templates/builtins.txt
+++ b/docs/ref/templates/builtins.txt
@@ -727,6 +727,18 @@ escaped, because it's not a format character::
This would display as "It is the 4th of September".
+.. versionchanged:: 1.4
+
+.. note::
+
+ The format passed can also be one of the predefined ones
+ :setting:`DATE_FORMAT`, :setting:`DATETIME_FORMAT`,
+ :setting:`SHORT_DATE_FORMAT` or :setting:`SHORT_DATETIME_FORMAT`.
+ The predefined formats may vary depending on the current locale and
+ if :ref:`format-localization` is enabled, e.g.::
+
+ It is {% now "SHORT_DATETIME_FORMAT" %}
+
.. templatetag:: regroup
regroup