Ideas and feedback regarding Localization
Some context: I'm building a system that relies heavily on localization. I will focus on the Pages table and it's relation with localization.
So,
I have a table called pages and it has three localized fields (title, mini body, body). Each of them is an integer that references the locales table. The locales table is structured like this: language_id, key, namespace, locale_type
Everything is self explanatory except from the locale_type. Locales are of two types. Short Locale and Text Locale. Short locales mainly consist of words and small phrases and the text locales are big content blocks like posts and pages. They are stored in different tables. Here is the locale short: local_id, language_id, locale
Back to the main question, how should i approach this issue? What would be the best way to loads the locales when a page is loaded through eloquent? Furthermore, what do you think about this way of structuring localization?
Thanks!
Please or to participate in this conversation.