ss d581d78eb7 初始化 10 meses atrás
..
Catalogue d581d78eb7 初始化 10 meses atrás
Command d581d78eb7 初始化 10 meses atrás
DataCollector d581d78eb7 初始化 10 meses atrás
DependencyInjection d581d78eb7 初始化 10 meses atrás
Dumper d581d78eb7 初始化 10 meses atrás
Exception d581d78eb7 初始化 10 meses atrás
Extractor d581d78eb7 初始化 10 meses atrás
Formatter d581d78eb7 初始化 10 meses atrás
Loader d581d78eb7 初始化 10 meses atrás
Reader d581d78eb7 初始化 10 meses atrás
Resources d581d78eb7 初始化 10 meses atrás
Util d581d78eb7 初始化 10 meses atrás
Writer d581d78eb7 初始化 10 meses atrás
CHANGELOG.md d581d78eb7 初始化 10 meses atrás
DataCollectorTranslator.php d581d78eb7 初始化 10 meses atrás
IdentityTranslator.php d581d78eb7 初始化 10 meses atrás
Interval.php d581d78eb7 初始化 10 meses atrás
LICENSE d581d78eb7 初始化 10 meses atrás
LoggingTranslator.php d581d78eb7 初始化 10 meses atrás
MessageCatalogue.php d581d78eb7 初始化 10 meses atrás
MessageCatalogueInterface.php d581d78eb7 初始化 10 meses atrás
MessageSelector.php d581d78eb7 初始化 10 meses atrás
MetadataAwareInterface.php d581d78eb7 初始化 10 meses atrás
PluralizationRules.php d581d78eb7 初始化 10 meses atrás
README.md d581d78eb7 初始化 10 meses atrás
Translator.php d581d78eb7 初始化 10 meses atrás
TranslatorBagInterface.php d581d78eb7 初始化 10 meses atrás
TranslatorInterface.php d581d78eb7 初始化 10 meses atrás
composer.json d581d78eb7 初始化 10 meses atrás

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 ! »

Resources