Updating the translation platform for OXID eShop
The last weekend I spent in Herdecke, Germany on invitation of my mate Daniel Schlichtholz, the main coder of the translation center oTranCe. oTranCe was originally invented for localizing and managing the language keys of Daniel’s other pet project, MySQLDumper, and is used as a localisation center for OXID eShop as well. So me and Daniel spent a plenty of time with updating the software oTranCe as well as the OXID eShop language keys, oTranCe manages. This is more or less a note to myself for documentary purposes.
The manual software update of oTranCe (there’s no new version yet, just wanted to get up-to-date) basically consists of three steps:
- Clone the original GitHub repository of the oTranCe project to your local machine and copy the following folders to your installation: application/, library/Msd/ and modules/
- Find the necessary database changes in docs/database/ and run the appropriate SQL files (best using MySQLDumper ^^). In this case I had to run the update SQL files 4, 5 and 6; it is not tragic if you use a SQL file that was already executed.
- The file application/configs/config.dist.ini may contain new database tables. Merge this information to your existing config.ini in the same folder.
Done – the software is up-to-date again. Please note again that this is not an official tutorial for updating oTranCe. When publishing the next version, oTranCe most likely will provide an own update script that takes over the steps described above.
With this update, the OXID’s translator community gets a couple of very cool new features as are:
- Git integration: besides an existing version control with SVN it is now possible to use Git and GitHub with it. The parameters can be set by an administrator. Every user with the right of exporting language files will now be able to hit the button for sending an update to your own repository on GitHub.
- In the past it was possible to use the Google translation API for suggested translations as an external service, we just never used it at OXID. Now the external service MyMemory is additionally available in oTranCe and switched on by default in the translation center of OXID eShop.
- Thanks to the contribution of Josef Roth to oTranCe, it is now possible to flag when a key in the default language was changed.
- Last not least it is possible now to change the order of the entries when clicking on the table headers in the overview (Home) and in statistics.
Hope you guys have fun with the new features. With the official update of oTranCe we will describe this new features more precisely incl. screenshots etc. on the oTranCe project’s home page.
As announced on OXIDforge, the language handling in OXID eShop was streamlined, and the new version came with a lot of changes in language keys at least for the store front that couldn’t be sorted out manually. For updating this language keys, I did the following steps:
- Export the language files (all languages) without replacement by the main language (English) in oTranCe
- Flush the oTranCe tables keys and translations
- Import the new language files for the main OXID eShop version 4.8 languages German and English with an admin user with the permission to add new language keys
- Switch off the permission to add new language keys for this admin user
- Import all other languages file by file
- Tag a new version 4.7 in GitHub and clean up the master repository with git rm
- Copy all other files belonging to the languages (flags, maps, transliteration lists etc.) to the export directory of the oTranCe installation and git add/git push them to origin master
That’s it. I will now inform the translator community about this update. Also I’ll have to adapt the tutorials about the language handling, and to think about how to maintain the language files of the modules delivered with the standard OXID eShop setup.