I am confused with how to proceed on Internationalization & Localizations, so I categorized a website’s data as follows :
-
Site Content : Content that is hosted by the website i.e. the data about the subject. Eg: Mobile Phone Site (Data about mobile models, specs, prices, etc.)
-
User Data : Data that is added by the users over time. Eg: Comments, reviews, profile info, etc.
-
UI Text : Static text that changes with the UI (Template). Eg: Menus, Footer, Header, etc.
Hope I categorized the data well.
Possible approach for translation :
from django.utils.translation import ugettext
What are other options ?
Translation Problem (Django) :
- Site Content (Dynamic) : How is possible to have
.pofiles for Dynamic content from the database ? (Is ugettext the right tool ?) - User Data (Dynamic) : How to translate this dynamic data ? (
.pofiles ?) what if a user comments in English and other in Spanish ? - UI Text (static) : This is static text that can be done with
.pofiles and could change with templates. So, is there a better way ?
How is i18n and l10n handled in practice ?
1 Answer