V
V
Vyacheslav2016-11-21 14:30:46
PHP
Vyacheslav, 2016-11-21 14:30:46

What should be the structure of the i18n table?

Good day,
At the moment I have a project on support, and it supports two languages ​​(ru, en) Through the i18n table. The project is handwritten and written in php.
Table structure
93e3b21276014b0c96be0a79cc645636.png
And so for each object there is such a scheme, and in the case of a country this is the simplest. If we take for example a product, then there are much more fields that are registered for each language.
Based on the above, when outputting each object, there is a connection with the i18n table.
I don't have much experience in programming, and therefore I'm wondering how correct this solution is?
Wouldn't it be easier to make a division into ru and en in each table? And do not call the same description from another table with a language check, but store everything in one place.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Ukolov, 2016-11-21
@alexey-m-ukolov

I usually make translatable tokens table rows and languages ​​columns. Languages ​​are added very rarely, and working with such a scheme is much more comfortable.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question