diff options
| author | Jannis Leidel <jannis@leidel.info> | 2010-05-16 20:48:19 +0000 |
|---|---|---|
| committer | Jannis Leidel <jannis@leidel.info> | 2010-05-16 20:48:19 +0000 |
| commit | 06ab9eeaf5b43b7020b68363a23d1aab2e844aa6 (patch) | |
| tree | c11b8d532553c6b067e4767738856ee25f5d273f /docs/ref/templates | |
| parent | 34ddcd9939568e7d19a0059647a9faaf36972083 (diff) | |
Added notes about the two new date format specifiers (``c`` and ``u``) added in 1.2. Thanks for the patch, Ramiro Morales.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13267 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs/ref/templates')
| -rw-r--r-- | docs/ref/templates/builtins.txt | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt index 393aab99e5..002aa3f416 100644 --- a/docs/ref/templates/builtins.txt +++ b/docs/ref/templates/builtins.txt @@ -723,6 +723,10 @@ escaped, because it's not a format character:: This would display as "It is the 4th of September". +.. versionadded:: 1.2 + +The ``c`` and ``u`` format specification characters were added in Django 1.2. + .. templatetag:: regroup regroup @@ -1132,8 +1136,8 @@ Formats a date according to the given format. Given format can be one of the predefined ones ``DATE_FORMAT``, ``DATETIME_FORMAT``, ``SHORT_DATE_FORMAT`` or ``SHORT_DATETIME_FORMAT``, -or a custom format, same as the `now`_ tag. Note that predefined formats may -vary depending on the current locale. +or a custom format, same as the :ttag:`now` tag. Note that predefined formats +may vary depending on the current locale. For example:: @@ -1780,11 +1784,12 @@ time Formats a time according to the given format. Given format can be the predefined one ``TIME_FORMAT``, or a custom format, -same as the `now`_ tag. Note that the predefined format is locale depending. +same as the :ttag:`now` tag. Note that the predefined format is locale- +dependant. The time filter will only accept parameters in the format string that relate to the time of day, not the date (for obvious reasons). If you need to -format a date, use the `date`_ filter. +format a date, use the :tfilter:`date` filter. For example:: |
