Since now your pages are configured to route to the desired internationalization you now need to provide localization yourself. They will not automatically be translated. You need to handle it yourself.
To do so you will have to mark the elements that need to be translated by using
from django.utils.translation import ugettext as _
Now mark the text that you need to translate by using ugettext as _
in the following way:-
class PollPluginPublisher(CMSPluginBase):
model = PollPluginModel # model where plugin data are saved
module = _("Polls")
name = _("Poll Plugin") # name of the plugin in the interface
Now the elements are marked to be translated in our case ("Polls") and ("Poll Plugin").
After dealing with this you can run following command in your root directory:-
django-admin makemessages -l de
Replace the last "de" with your language locale name. What this command does is that it will create the po file which will just store the elements that need to be translated. Be sure that your LOCALE_PATH
is set properly.
After this done you can use the following django-packages for translations:-
1) django-rosetta :- https://django-rosetta.readthedocs.io/en/latest/
2) django-modeltranslation:- http://django-modeltranslation.readthedocs.io/en/latest/
For further reference of LOCALIZATION you can view:-
https://docs.djangoproject.com/en/1.10/topics/i18n/translation/#localization-how-to-create-language-files