diff -r 275034865933 docs/howto/i18n.txt
|
a
|
b
|
|
| 6 | 6 | |
| 7 | 7 | At runtime, Django looks for translations by following this algorithm: |
| 8 | 8 | |
| 9 | | * First, it looks for a ``locale`` directory in the application directory |
| 10 | | of the view that's being called. If it finds a translation for the |
| 11 | | selected language, the translation will be installed. |
| 12 | | * Next, it looks for a ``locale`` directory in the project directory. If it |
| 13 | | finds a translation, the translation will be installed. |
| | 9 | * First, it looks for a ``locale`` directory in the directory containing |
| | 10 | your settings file. |
| | 11 | * Second, it looks for a ``locale`` directory in the project directory. |
| | 12 | * Third, it looks for a ``locale`` directory in each of the installed apps. |
| | 13 | It does this in the reverse order of INSTALLED_APPS |
| 14 | 14 | * Finally, it checks the Django-provided base translation in |
| 15 | 15 | ``django/conf/locale``. |
| 16 | 16 | |
diff -r 275034865933 docs/topics/i18n/deployment.txt
|
a
|
b
|
|
| 178 | 178 | As described in :ref:`using-translations-in-your-own-projects`, |
| 179 | 179 | at runtime, Django looks for translations by following this algorithm: |
| 180 | 180 | |
| 181 | | * First, it looks for a ``locale`` directory in the application directory |
| 182 | | of the view that's being called. If it finds a translation for the |
| 183 | | selected language, the translation will be installed. |
| 184 | | * Next, it looks for a ``locale`` directory in the project directory. If it |
| 185 | | finds a translation, the translation will be installed. |
| | 181 | * First, it looks for a ``locale`` directory in the directory containing |
| | 182 | your settings file. |
| | 183 | * Second, it looks for a ``locale`` directory in the project directory. |
| | 184 | * Third, it looks for a ``locale`` directory in each of the installed apps. |
| | 185 | It does this in the reverse order of INSTALLED_APPS |
| 186 | 186 | * Finally, it checks the Django-provided base translation in |
| 187 | 187 | ``django/conf/locale``. |
| 188 | 188 | |