unknown a0372a28bb second commit 2 달 전
..
Catalogue a0372a28bb second commit 2 달 전
Command a0372a28bb second commit 2 달 전
DataCollector a0372a28bb second commit 2 달 전
DependencyInjection a0372a28bb second commit 2 달 전
Dumper a0372a28bb second commit 2 달 전
Exception a0372a28bb second commit 2 달 전
Extractor a0372a28bb second commit 2 달 전
Formatter a0372a28bb second commit 2 달 전
Loader a0372a28bb second commit 2 달 전
Provider a0372a28bb second commit 2 달 전
Reader a0372a28bb second commit 2 달 전
Resources a0372a28bb second commit 2 달 전
Test a0372a28bb second commit 2 달 전
Util a0372a28bb second commit 2 달 전
Writer a0372a28bb second commit 2 달 전
CHANGELOG.md a0372a28bb second commit 2 달 전
CatalogueMetadataAwareInterface.php a0372a28bb second commit 2 달 전
DataCollectorTranslator.php a0372a28bb second commit 2 달 전
IdentityTranslator.php a0372a28bb second commit 2 달 전
LICENSE a0372a28bb second commit 2 달 전
LocaleSwitcher.php a0372a28bb second commit 2 달 전
LoggingTranslator.php a0372a28bb second commit 2 달 전
MessageCatalogue.php a0372a28bb second commit 2 달 전
MessageCatalogueInterface.php a0372a28bb second commit 2 달 전
MetadataAwareInterface.php a0372a28bb second commit 2 달 전
PseudoLocalizationTranslator.php a0372a28bb second commit 2 달 전
README.md a0372a28bb second commit 2 달 전
StaticMessage.php a0372a28bb second commit 2 달 전
TranslatableMessage.php a0372a28bb second commit 2 달 전
Translator.php a0372a28bb second commit 2 달 전
TranslatorBag.php a0372a28bb second commit 2 달 전
TranslatorBagInterface.php a0372a28bb second commit 2 달 전
composer.json a0372a28bb second commit 2 달 전

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

Help Symfony by sponsoring its development!

Resources