Currently the language definitions are stored completely in several flat files (lang.php, see http://www.oxid-esales.com/forum/showthread.php?t=1947). Therefore, changing the shop texts is only possible for the shop owner if he is able to use a text editor and has user privileges to access different shop directories (e.g. /shop/out/basic/en/lang.php). Most shop owners want to alter the template texts according to their need.
The current technique of changing the language definitions in lang.php files has several drawbacks:
- Most shop owners are not able to use a text editor to change the language definitions.
- A shop owner should not have the right to access the directories which hold the language definitions because of security constraints.
- Also, it’s to dangerous to let someone without php knowledge change php files. One syntax error, and the whole language definition could not be read anymore.
- Usually a show owner doesn’t want to work anywhere else than in the shop admininstration.
Nevertheless the shop owner should be able and often wants to alter the different shop texts without the help of a shop developer.
Therefore I’d like to propose a change of the current language implementation technique:
All language definitions should be hold in the database and no more in flat files (let’s say, a “template cms” compared with the normal cms).
There are different advantages in storing language definitions in the database instead of lang.php:
- The shop owner is now able to change the text definitions by himself.
- The danger of creating bugs when changing the language definitions is zero.
- New languages could be added simply by the shop owner himself.
- Third party shop translaters could have access to this special “template cms”.
I don’t think that there will be any performance issues if the database table with the language definitions is called once to initalize the language array. This should not make much difference to the current method. If this is an issue it would be possible to offer the old method as an option.
I am very sure that show owners would appreciate this described. method. And by the way I am sure that shop developers would appreciate this method, too: It’s very boring for a developer to have to change shop texts in lang.php.