EtonDigital / EDBlogBundle

EDBlogBundle is extensive and user friendly blog bundle for Symfony2. It provides a lot of interesting features that makes a serious bloging platform from your Symfony2 application. It is very intuitive and flexible, you can easily fit it to your own needs.
MIT License
35 stars 20 forks source link

Multilanguage support #32

Open ciro-webcom opened 7 years ago

ciro-webcom commented 7 years ago

Hi,

First of all, I want to thank you for your work, this bundle saves me a lot of work. Can you tell me what is the best way to use the bundle for a multilangage blog? I wanted to put a property $locale in articles, categories and tags entities but if I do that, I have to change repositories. For example ArticleRepository functions to get articles collection in a given language, and a lot of other things in templates, such as the sortableTh macro, in wich I have to put the locale parameter for the given route and all the routes parameters for list and create action, because the controller needs to know the locale.

What is the best way to do what I want?

Thank you

7tomas7 commented 6 years ago

@ciro-webcom I have similar problem, can you tell us how did you resolve the problem?

ciro-webcom commented 6 years ago

Hi, I don't remember well, but I think the best way is to fork the repo and add a column locale on articles and categories tables, and change the queries in the repositories including the locale parameter. I also didin't use the original templates, so I didn't had to change the twig files

7tomas7 commented 6 years ago

@ciro-webcom thanks !