I use FOSUser bundle and rewrite registration form, and there i use entity type for select country, region, etc. This entities have relation with user locale, and i want write DQL for each locale.
How I can get user locale in form without rewriting FOSUser:registerAction?
I use FOSUser bundle and rewrite registration form, and there i use entity type
Share
You can get user locale like this
$locale = $this->get('session')->getLocale();from your controller, or you should pass locale or whole session object into form type constructor defined like this.MyFormType.php
config.yml