Kirin 93a3391a21 init 11 mesiacov pred
..
Catalogue 93a3391a21 init 11 mesiacov pred
Command 93a3391a21 init 11 mesiacov pred
DataCollector 93a3391a21 init 11 mesiacov pred
DependencyInjection 93a3391a21 init 11 mesiacov pred
Dumper 93a3391a21 init 11 mesiacov pred
Exception 93a3391a21 init 11 mesiacov pred
Extractor 93a3391a21 init 11 mesiacov pred
Formatter 93a3391a21 init 11 mesiacov pred
Loader 93a3391a21 init 11 mesiacov pred
Provider 93a3391a21 init 11 mesiacov pred
Reader 93a3391a21 init 11 mesiacov pred
Resources 93a3391a21 init 11 mesiacov pred
Test 93a3391a21 init 11 mesiacov pred
Util 93a3391a21 init 11 mesiacov pred
Writer 93a3391a21 init 11 mesiacov pred
CHANGELOG.md 93a3391a21 init 11 mesiacov pred
DataCollectorTranslator.php 93a3391a21 init 11 mesiacov pred
IdentityTranslator.php 93a3391a21 init 11 mesiacov pred
LICENSE 93a3391a21 init 11 mesiacov pred
LoggingTranslator.php 93a3391a21 init 11 mesiacov pred
MessageCatalogue.php 93a3391a21 init 11 mesiacov pred
MessageCatalogueInterface.php 93a3391a21 init 11 mesiacov pred
MetadataAwareInterface.php 93a3391a21 init 11 mesiacov pred
PseudoLocalizationTranslator.php 93a3391a21 init 11 mesiacov pred
README.md 93a3391a21 init 11 mesiacov pred
TranslatableMessage.php 93a3391a21 init 11 mesiacov pred
Translator.php 93a3391a21 init 11 mesiacov pred
TranslatorBag.php 93a3391a21 init 11 mesiacov pred
TranslatorBagInterface.php 93a3391a21 init 11 mesiacov pred
composer.json 93a3391a21 init 11 mesiacov pred

README.md

Translation Component

The Translation component provides tools to internationalize your application.

Getting Started

$ composer require symfony/translation
use Symfony\Component\Translation\Translator;
use Symfony\Component\Translation\Loader\ArrayLoader;

$translator = new Translator('fr_FR');
$translator->addLoader('array', new ArrayLoader());
$translator->addResource('array', [
    'Hello World!' => 'Bonjour !',
], 'fr_FR');

echo $translator->trans('Hello World!'); // outputs « Bonjour ! »

Sponsor

The Translation component for Symfony 5.4/6.0 is backed by:

  • Crowdin, a cloud-based localization management software helping teams to go global and stay agile.
  • Lokalise, a continuous localization and translation management platform that integrates into your development workflow so you can ship localized products, faster.

Help Symfony by sponsoring its development!

Resources