Translation

Web Security Map uses the Django translation system.

We’ve tried to automate most of the quirks this system has to make translations straightforward.

This tutorial assumes you’ve got a working installation, follow the quickstart

Adding a language

A list of languages is stored in /websecmap/settings.py. You can modify the LANGUAGES variable to add your language. We prefer that you use the 2-letter ISO country codes where possible, but we already break from that with some languages.

To change Web Security Map to the language you’re working on, set the LANGUAGE_CODE to your language and run Web Security Map.

Once your language has been added and you’ve changed the default language, run:

websecmap translate

This will create the language files for your languages here:

  • /websecmap/map/locale/’iso code’/django.po
  • /websecmap/map/locale/’iso code’/djangojs.po

And for other “django apps” like “map” accordingly.

You can edit the .po files, they will be converted to those .mo files for some reason.

After you’re done editing, run:

websecmap translate

Translations should then shown up on the website.