Django CMS 2.4.x Documentation
either via {% language %} templatetag or via activate("de") function call in views. Before: {% url "de:myview" %} After: {% load i18n %}{% language "de" %} {% url "myview_name" %} {% endlanguage %} • reverse 'en', 'name': gettext('English'), 'fallbacks': ['de', 'fr'], 'public': True, 'hide_untranslated': True, 'redirect_on_fallback':False, }, { 'code': 'de', 'name': gettext('Deutsch'), 'fallbacks': ['en', 'name': gettext('Dutch'), 'public': True, 'fallbacks': ['en'], }, ], 'default': { 'fallbacks': ['en', 'de', 'fr'], 'redirect_on_fallback':True, 'public': False, 'hide_untranslated': False, } } For more details0 码力 | 104 页 | 709.98 KB | 6 月前3Django CMS 3.0.x Documentation
yes • Languages to enable. Option can be provided multiple times, or as a comma separated list: en, de • Optional default time zone: America/Chicago: • Activate Django timezone support: yes • Activate CMS the same url but in a different language use the language template tag: {% load i18n %} {% language "de" %} 46 Chapter 5. Table of contents django cms Documentation, Release 3.0.19.dev1 {% url myapp_namespace:app_main template tag returns the URL of the current page in another language. Example: {% page_language_url "de" %} hide_untranslated If you add a default directive to your CMS_LANGUAGES with a hide_untranslated0 码力 | 180 页 | 1.56 MB | 6 月前3Django CMS 2.2.x Documentation
Defines the languages available in django CMS. Example: CMS_LANGUAGES = ( ('fr', gettext('French')), ('de', gettext('German')), ('en', gettext('English')), ) Note: Make sure you only define languages which Getting Started django cms Documentation, Release 2.2.1 Example: CMS_LANGUAGE_CONF = { 'de': ['en', 'fr'], 'en': ['de'], } CMS_SITE_LANGUAGES Default: {} If you have more than one site and CMS_LANGUAGES differs the admin you only get the languages available on this site. Example: CMS_SITE_LANGUAGES = { 1:['en','de'], 2:['en','fr'], 3:['en'], } CMS_FRONTEND_LANGUAGES Default: Value of CMS_LANGUAGES A list of languages0 码力 | 76 页 | 627.98 KB | 6 月前3Django CMS 3.11.10 Documentation
are not migrating a version 3 project Add to settings.py: LANGUAGES = [ ("en", "English"), ("de", "German"), ("it", "Italian"), ] LANGUAGE_CODE = "en" pip install psycopg2 # for Postgres user, in the following order of preference: language code in the URL - for example, http://example.com/de (when multilingual URLs are enabled) language stored in the browsing session language stored in a cookie "whoosh_index_en"), }, "de": { "ENGINE": "haystack.backends.whoosh_backend.WhooshEngine", "PATH": os.path.join(ROOT_DIR, "search_index", "whoosh_index_de"), } } ... from haystack0 码力 | 493 页 | 1.44 MB | 6 月前0.03Django CMS 2.3.x Documentation
Defines the languages available in django CMS. Example: CMS_LANGUAGES = ( ('fr', gettext('French')), ('de', gettext('German')), ('en', gettext('English')), ) Note: Make sure you only define languages which Default: {} Language fallback ordering for each language. Example: CMS_LANGUAGE_CONF = { 'de': ['en', 'fr'], 'en': ['de'], } CMS_SITE_LANGUAGES Default: {} If you have more than one site and CMS_LANGUAGES differs only get the languages available to that particular site. Example: CMS_SITE_LANGUAGES = { 1:['en','de'], 2:['en','fr'], 3:['en'], } CMS_FRONTEND_LANGUAGES Default: Value of CMS_LANGUAGES A list of languages0 码力 | 92 页 | 666.41 KB | 6 月前3django cms 3.1.x Documentation
yes • Languages to enable. Option can be provided multiple times, or as a comma separated list: en, de • Optional default time zone: America/Chicago: • Activate Django timezone support: yes • Activate the same url but in a different language use the language template tag: {% load i18n %} {% language "de" %} {% url myapp_namespace:app_main %} {% endlanguage %} Note: The official Django documentation Example: 5.3. Key topics 83 django cms Documentation, Release 3.1.8.dev1 {% page_language_url "de" %} hide_untranslated If you add a default directive to your CMS_LANGUAGES with a hide_untranslated0 码力 | 200 页 | 1.63 MB | 1 年前3Django CMS 2.4.x Documentation
either via {% language %} templatetag or via activate("de") function call in views. Before: {% url "de:myview" %} After: {% load i18n %}{% language "de" %} {% url "myview_name" %} {% endlanguage %} reverse 'fallbacks': ['de', 'fr'], 'public': True, 'hide_untranslated': True, 'redirect_on_fallback':False, }, { 'code': 'de', 'fallbacks': ['en'], }, ], 'default': { 'fallbacks': ['en', 'de', 'fr'], 'redirect_on_fallback':True, 'public': False, 'hide_untranslated':0 码力 | 156 页 | 727.78 KB | 6 月前3django cms 3.10.x Documentation
and must include the language in LANGUAGE_CODE. For example: LANGUAGES = [ ('en', 'English'), ('de', 'German'), ] (For simplicity’s sake, at this stage it is worth changing the default en-us in that page_language_url returns the URL of the current page in another language. Example: {% page_language_url "de" %} 44 Chapter 4. Software version requirements and release notes django cms Documentation, Release must subclass cms.wizards.wizard_base.Wizard to use it. This is because each wizard’s uniqueness is de- termined by its class and module name. See the Reference section on wizards for technical details0 码力 | 296 页 | 1.79 MB | 1 年前3django cms 4.1.x Documentation
and must include the language in LANGUAGE_CODE. For example: LANGUAGES = [ ("en", "English"), ("de", "German"), ("it", "Italian"), ] LANGUAGE_CODE = "en" (For simplicity’s sake, at this stage it is in the following order of preference: • language code in the URL - for example, http://example.com/de (when multilingual URLs are enabled) • language stored in the browsing session • language stored page_language_url returns the URL of the current page in another language. Example: {% page_language_url "de" %} Configuring language-handling behaviour CMS_LANGUAGES describes the all options available for0 码力 | 357 页 | 1.99 MB | 1 年前3django cms 4.1.1 Documentation
and must include the language in LANGUAGE_CODE. For example: LANGUAGES = [ ("en", "English"), ("de", "German"), ("it", "Italian"), ] LANGUAGE_CODE = "en" (For simplicity’s sake, at this stage it is in the following order of preference: • language code in the URL - for example, http://example.com/de (when multilingual URLs are enabled) • language stored in the browsing session • language stored page_language_url returns the URL of the current page in another language. Example: {% page_language_url "de" %} Configuring language-handling behaviour CMS_LANGUAGES describes the all options available for0 码力 | 361 页 | 2.00 MB | 1 年前3
共 54 条
- 1
- 2
- 3
- 4
- 5
- 6