Support the ongoing development of →
Database Eloquent Architecture
Last updated 2 years ago.

Hello @romin4you, I 've created a package igaster/laravel-translate-eloquent that adds translation to any Eloquent Model. It requires only one additional table in your DB where the translations will be stored...

You can get/set a translated key as it was a normal Eloquent key (eg $article->title), when actually the correct translation will be looked up and returned from the Translations table... Of course you can request a translation to any locale.

  • It supports a fallback locale if there is no translation in the current locale.

Hope it is usefull... Cheers!

Last updated 8 years ago.

Sign in to participate in this thread!


Your banner here too?

romin4you romin4you Joined 28 Oct 2015


We'd like to thank these amazing companies for supporting us

Your logo here?

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 - All rights reserved.