Many times when project is almost ready customer brings you a change request and say:
"We forget about language versions so there will be 4 of them for the entire site"
Budget is burned. It's late at night. You need a miracle.
The miracle tutorial begins here:
Simply add those two to your composer.json file:
$php composer.phar update
Enable the bunldes in your
$bundles = array (
locales: [de, en, pl]
So right now you got 3 languages enabled on your site. Check it just by entiering your project with
acmedemoapp.com/en prefix :)
look at the:
php app/console router:debug
So many localized routes! YAY!
Ok but i still got only one messages translation.
Extract string to translations from your code!
ekhm... I can't gettext dude.
Use the symfony command luke!
~ Master Yoda
Just like that:
$php app/console translation:extract pl --bundle=AcmeDemoBundle --enable-extractor=jms_i18n_routing --output-format=yml --exclude-dir=Tests
It don't go I'm using behat and throws an error.
Repeat this for all your bundles.
You can send the translations file to the customer. They will take care of the rest!