Fix the settings about DATE_FORMAT*S*. Fix 540

This commit is contained in:
Alexis Métaireau 2012-10-12 22:20:47 +02:00
commit 7892c33ec9

View file

@ -204,14 +204,14 @@ Have a look at `the wikipedia page`_ to get a list of valid timezone values.
Date format and locale Date format and locale
---------------------- ----------------------
If no DATE_FORMAT is set, fall back to DEFAULT_DATE_FORMAT. If you need to If no DATE_FORMATS is set, fall back to DEFAULT_DATE_FORMAT. If you need to
maintain multiple languages with different date formats, you can set this dict maintain multiple languages with different date formats, you can set this dict
using language name (``lang`` in your posts) as key. Regarding available format using language name (``lang`` in your posts) as key. Regarding available format
codes, see `strftime document of python`_ : codes, see `strftime document of python`_ :
.. parsed-literal:: .. parsed-literal::
DATE_FORMAT = { DATE_FORMATS = {
'en': '%a, %d %b %Y', 'en': '%a, %d %b %Y',
'jp': '%Y-%m-%d(%a)', 'jp': '%Y-%m-%d(%a)',
} }
@ -230,13 +230,13 @@ above:
.. parsed-literal:: .. parsed-literal::
# On Unix/Linux # On Unix/Linux
DATE_FORMAT = { DATE_FORMATS = {
'en': ('en_US','%a, %d %b %Y'), 'en': ('en_US','%a, %d %b %Y'),
'jp': ('ja_JP','%Y-%m-%d(%a)'), 'jp': ('ja_JP','%Y-%m-%d(%a)'),
} }
# On Windows # On Windows
DATE_FORMAT = { DATE_FORMATS = {
'en': ('usa','%a, %d %b %Y'), 'en': ('usa','%a, %d %b %Y'),
'jp': ('jpn','%Y-%m-%d(%a)'), 'jp': ('jpn','%Y-%m-%d(%a)'),
} }