=====
langswitch
=====
langswitch - is django app, that can be used on multilingual sites to allow users switch site language, and use some template tags for maintain multilang links etc.
Quick start
-----------
1. Add "langswitch" to your INSTALLED_APPS setting like this::
INSTALLED_APPS = (
...
'langswitch',
)
and make sure that you have django.core.context_processors.request in TEMPLATE_CONTEXT_PROCESSORS:
TEMPLATE_CONTEXT_PROCESSORS = (
...
'django.core.context_processors.request',
...
)
2. Load langswitch in your template:
{% load lang_switch %}
3. Use template tag {% set_lang_from_path %} to activate translation, from url path (like /en/example/article/ for english language or /ru/example/article/ for russian)
this tag also defines variable 'lang' in template context, so you can use it.
4. Also you can just get variable 'lang' to template context with {% get_lang %} template tag
langswitch
=====
langswitch - is django app, that can be used on multilingual sites to allow users switch site language, and use some template tags for maintain multilang links etc.
Quick start
-----------
1. Add "langswitch" to your INSTALLED_APPS setting like this::
INSTALLED_APPS = (
...
'langswitch',
)
and make sure that you have django.core.context_processors.request in TEMPLATE_CONTEXT_PROCESSORS:
TEMPLATE_CONTEXT_PROCESSORS = (
...
'django.core.context_processors.request',
...
)
2. Load langswitch in your template:
{% load lang_switch %}
3. Use template tag {% set_lang_from_path %} to activate translation, from url path (like /en/example/article/ for english language or /ru/example/article/ for russian)
this tag also defines variable 'lang' in template context, so you can use it.
4. Also you can just get variable 'lang' to template context with {% get_lang %} template tag
Release files for django-langswitch 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| django-langswitch-0.1.1.zip | 6.4 kB | Details |
Release files / django-langswitch-0.1.1.zip
| Download URL | django-langswitch-0.1.1.zip |
|---|---|
| Size | 6.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
99f6faeab11ed870aa7f3f92e2acfa73993328cb491994e4de1107af4862669e
|
|
BLAKE2b-256 checksum How to use checksums |
c9aaea1f2c98a9b5e5712e2b0aa3b847387cff5f6d5e33f111d80dec38d606b7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |