jun 241d78f74c first commit пре 4 дана
..
Catalogue 241d78f74c first commit пре 4 дана
Command 241d78f74c first commit пре 4 дана
DataCollector 241d78f74c first commit пре 4 дана
DependencyInjection 241d78f74c first commit пре 4 дана
Dumper 241d78f74c first commit пре 4 дана
Exception 241d78f74c first commit пре 4 дана
Extractor 241d78f74c first commit пре 4 дана
Formatter 241d78f74c first commit пре 4 дана
Loader 241d78f74c first commit пре 4 дана
Provider 241d78f74c first commit пре 4 дана
Reader 241d78f74c first commit пре 4 дана
Resources 241d78f74c first commit пре 4 дана
Test 241d78f74c first commit пре 4 дана
Util 241d78f74c first commit пре 4 дана
Writer 241d78f74c first commit пре 4 дана
CHANGELOG.md 241d78f74c first commit пре 4 дана
DataCollectorTranslator.php 241d78f74c first commit пре 4 дана
IdentityTranslator.php 241d78f74c first commit пре 4 дана
LICENSE 241d78f74c first commit пре 4 дана
LoggingTranslator.php 241d78f74c first commit пре 4 дана
MessageCatalogue.php 241d78f74c first commit пре 4 дана
MessageCatalogueInterface.php 241d78f74c first commit пре 4 дана
MetadataAwareInterface.php 241d78f74c first commit пре 4 дана
PseudoLocalizationTranslator.php 241d78f74c first commit пре 4 дана
README.md 241d78f74c first commit пре 4 дана
TranslatableMessage.php 241d78f74c first commit пре 4 дана
Translator.php 241d78f74c first commit пре 4 дана
TranslatorBag.php 241d78f74c first commit пре 4 дана
TranslatorBagInterface.php 241d78f74c first commit пре 4 дана
composer.json 241d78f74c first commit пре 4 дана

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