The translations are stored in the .po
format. The .po
file structure adopted by the CS-Cart & Multi-Vendor software is different from the generally accepted gettext-driven standard [#gettext_po] for the sake of simplicity.
Each .po
file contains some necessary metadata in the header:
# Base pack of "English" language variables msgid "" msgstr "" "Language: en\n" "Content-Type: text/plain; charset=UTF-8\n" "Pack-Name: English\n" "Lang-Code: en\n" "Country-Code: US\n"
Warning
Do not change the existing metadata.
Though, some editors may add extra metadata, and that is OK (extra data is ignored).
Here is an example of a valid language variable definition:
#. Enable support of fraud notification msgctxt "Languages" msgid "2co_enable_fraud_verification" msgstr "Enable support of fraud notification"
msgctxt
—contextmsgid
—unique title to identify the language variablemsgstr
—value in the selected languageLanguage variable definitions must be separated from each other with an empty line.
Here is how a .po
file could end:
# Base pack of "English" language variables msgid "" msgstr "" "Language: en\n" "Content-Type: text/plain; charset=UTF-8\n" "Pack-Name: English\n" "Lang-Code: en\n" "Country-Code: US\n" #. Enable support of fraud notification msgctxt "Languages" msgid "2co_enable_fraud_verification" msgstr "Enable support of fraud notification" #. Status for orders with failed fraud review msgctxt "Languages" msgid "2co_fraud_fail" msgstr "Status for orders with failed fraud review"
Important
The file must end with an empty line.
Footnotes
[1] | Gettext on Wikipedia |
Questions & Feedback
Have any questions that weren't answered here? Need help with solving a problem in your online store? Want to report a bug in our software? Find out how to contact us.