PHPackages                             pleinx/php-multilang-any - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. pleinx/php-multilang-any

ActiveLibrary[Localization &amp; i18n](/categories/localization)

pleinx/php-multilang-any
========================

A simple resolver for language snippets.

2.0.0(4y ago)3552MITPHPPHP &gt;=5.6

Since May 24Pushed 4y ago1 watchersCompare

[ Source](https://github.com/pleinx/php-multilang-any)[ Packagist](https://packagist.org/packages/pleinx/php-multilang-any)[ Docs](https://github.com/pleinx/php-multilang-any)[ RSS](/packages/pleinx-php-multilang-any/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (5)DependenciesVersions (7)Used By (0)

[![Latest Stable Version](https://camo.githubusercontent.com/62c4a94e05e0740da72f491a305835c39000566b91891755425de647661b12b7/68747470733a2f2f706f7365722e707567782e6f72672f706c65696e782f7068702d6d756c74696c616e672d616e792f762f737461626c65)](https://packagist.org/packages/pleinx/php-multilang-any)[![Total Downloads](https://camo.githubusercontent.com/f89bbe894a05d54c1b6a2b9f7291f015e78702c98b137294e953f4415356d037/68747470733a2f2f706f7365722e707567782e6f72672f706c65696e782f7068702d6d756c74696c616e672d616e792f646f776e6c6f616473)](https://packagist.org/packages/pleinx/php-multilang-any)[![compatible](https://camo.githubusercontent.com/f52f20e005d9ab59bd1c916268d94d01fbbf37e90a2a43f3327e6bd2e60e2c49/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f504850253230372d436f6d70617469626c652d627269676874677265656e2e737667)](https://camo.githubusercontent.com/f52f20e005d9ab59bd1c916268d94d01fbbf37e90a2a43f3327e6bd2e60e2c49/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f504850253230372d436f6d70617469626c652d627269676874677265656e2e737667)[![License](https://camo.githubusercontent.com/0f2c7285dcd01c6b893d746a8f9d327ad0904bd8dbf38f43e7c2f960c08a5e38/68747470733a2f2f706f7365722e707567782e6f72672f706c65696e782f7068702d6d756c74696c616e672d616e792f6c6963656e7365)](https://packagist.org/packages/pleinx/php-multilang-any)

##### fyi: Currently not complete documented :-) Working on it...

[](#fyi-currently-not-complete-documented---working-on-it)

#### Description

[](#description)

Handles easy your translations for your multi language PHP Project.

#### Basic Features

[](#basic-features)

- [Production/Debug Modus](https://github.com/pleinx/php-multilang-any/wiki)
- [JSON-Files](https://github.com/pleinx/php-multilang-any/wiki) as Language-Resource
- Efficient loading of [Language-Packages](https://github.com/pleinx/php-multilang-any/wiki)
- [Automatic detection](https://github.com/pleinx/php-multilang-any/wiki) of Language (optional)

#### Translator Features

[](#translator-features)

- Write your [own Translate](https://github.com/pleinx/php-multilang-any/wiki) Function like `__('foo', ['bar'])`
- Supports HTML-Markup in Translation

Installation via Composer
-------------------------

[](#installation-via-composer)

```
composer require pleinx/php-multilang-any
```

##### Don't have Composer?

[](#dont-have-composer)

Just download it here:

Basic Usage
-----------

[](#basic-usage)

```
Translate::__e('Foo', ['Bar']);
// Output "Foo is nicer than Bar"
```

By default the `TranslatorAPI` load the Translations in `./languageFiles/`.

**Notice:** You find all these default parameters [here](https://github.com/pleinx/php-multilang-any/wiki).

Customize
---------

[](#customize)

```
$settings = (new TranslatorSettings())
    ->setIsProduction(false)
    ->setLanguage('de')
    ->setFallbackLanguage('en')
    ->setLanguageFilesPath(__DIR__ . '/lang');

new TranslatorAPI($settings);
```

**Notice:** Or just change the Default Settings, see [here](https://github.com/pleinx/php-multilang-any/wiki).

#### Language Resource Example (JSON)

[](#language-resource-example-json)

```
// package_serach.json
{
    "results.success.text": "Your search Results for {{searchTerm}}.",
    "results.failed.text": "Nothing found for {{searchTerm}}",
    "results.success.itemsInCategories": "Found {{itemsCount}} in {{categories}}"
}
```

#### Requirements

[](#requirements)

- PHP 7.4 and above (tested with php8)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~412 days

Total

5

Last Release

1626d ago

Major Versions

v0.1 → 1.0.02020-01-17

1.0.2 → 2.0.02021-11-30

### Community

---

Top Contributors

[![pleinx](https://avatars.githubusercontent.com/u/11060882?v=4)](https://github.com/pleinx "pleinx (26 commits)")

---

Tags

i18nmultilanguagetranslationstranslations-apitranslator

### Embed Badge

![Health badge](/badges/pleinx-php-multilang-any/health.svg)

```
[![Health](https://phpackages.com/badges/pleinx-php-multilang-any/health.svg)](https://phpackages.com/packages/pleinx-php-multilang-any)
```

###  Alternatives

[symfony/translation

Provides tools to internationalize your application

6.6k836.5M2.1k](/packages/symfony-translation)[nesbot/carbon

An API extension for DateTime that supports 281 different languages.

169661.4M4.8k](/packages/nesbot-carbon)[joedixon/laravel-translation

A tool for managing all of your Laravel translations

717911.4k11](/packages/joedixon-laravel-translation)[illuminate/translation

The Illuminate Translation package.

6936.4M495](/packages/illuminate-translation)[lajax/yii2-translate-manager

Translation management extension for Yii 2

227578.8k13](/packages/lajax-yii2-translate-manager)[larswiegers/laravel-translations-checker

Make sure your laravel translations are checked and are included in all languages.

256423.2k2](/packages/larswiegers-laravel-translations-checker)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
