Hey, i am currently working on a django app for my studies, and came to the point of l18n. Localizing the site itself was very easy, but now i have to allow users, to translate the dynamic content of the application. Users can save "products" in the database and give them names and descriptions, but since the whole site should be localized, i must provide a way of translating theses names and descriptions to the users.
Is there a natural way in django to do this? Or do i have to realize it as part of the application (by representing the translations in the datamodel)
Thanks, Janosch
I would suggest checking out django-multilingual. It is a third party app that lets you define translation fields on your models.
Of course, you still have to type in the actual translations, but they are stored transparently in the database (as opposed to in static PO files), which is what I believe you are asking about.
I use django-multilingual for localize content and django-localeurl for choosing language based on url (for example mypage/en/).
You can see how multilingua and localeurl work on JewishKrakow.net page.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With