PHPackages                             northcreationagency/silverstripe-lingo - 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. northcreationagency/silverstripe-lingo

ActiveSilverstripe-vendormodule[Localization &amp; i18n](/categories/localization)

northcreationagency/silverstripe-lingo
======================================

Translate and handle keys from yml-files from within the SilverStripe admin.

1.0.7(3y ago)31.4k2[2 issues](https://github.com/northcreation-agency/silverstripe-lingo/issues)BSD-3-ClausePHPCI failing

Since Oct 27Pushed 3y ago5 watchersCompare

[ Source](https://github.com/northcreation-agency/silverstripe-lingo)[ Packagist](https://packagist.org/packages/northcreationagency/silverstripe-lingo)[ Docs](https://github.com/northcreation-agency/silverstripe-lingo)[ RSS](/packages/northcreationagency-silverstripe-lingo/feed)WikiDiscussions master Synced yesterday

READMEChangelog (8)Dependencies (3)Versions (9)Used By (0)

Lingo
=====

[](#lingo)

Lingo lets developers define keys in yml-files in the same style as the normal lang-files but that can be viewed and translated from within the SilverStripe admin.

Requirements
------------

[](#requirements)

- SilverStripe 4 (tested with 4.12 and PHP 8.1.0)

Installation
------------

[](#installation)

`composer require northcreationagency/silverstripe-lingo`

How to use
----------

[](#how-to-use)

Set the location of the file/s that should be used for the texts to be handled in the yml config file of your project, ie: `app/_config/mysite.yml`

`moduleCatalog` is the catalog that the `textCatalog` is placed in (at the "first level").

`textCatalog` is the catalog that will contain the yml-files to be read by the module.

Example: app/lingotext

Where `app` is the "moduleCatalog" and `lingotext` is the "textCatalog".

[![image](https://user-images.githubusercontent.com/1150252/213942223-30541b46-41d6-44d6-b052-1bb76114677e.png)](https://user-images.githubusercontent.com/1150252/213942223-30541b46-41d6-44d6-b052-1bb76114677e.png)

```
NorthCreationAgency\SilverStripeLingo\Lingo:
  moduleCatalog: app
  textCatalog: lingotext

```

Place one or more yml-files (one for each language) for your texts in the `textCatalog` catalog. The files should follow the same structure as SilverStripes yml lang files. Example:

```
en:
  List:
    Header: 'This is a list header'
  Company:
    Header: This is a company header

```

### Sync the texts to the database

[](#sync-the-texts-to-the-database)

To sync the texts from the yml files to the database add a url variable to the build url, like this: `dev/build?synclingo=1`

Then when you run `dev/build?synclingo=1` the texts in the yml-file(s) are read and stored in the database and can be edited from the admin. The Lingo cache is also cleared on build.

You can also add an extra config variable if you want it to always sync the lingo texts upon build. If you do the config like this the lingo texts will be read and synced to the database upon every `dev/build` without the need to use the url variable.

```
NorthCreationAgency\SilverStripeLingo\Lingo:
  moduleCatalog: app
  textCatalog: lingotext
  syncOnBuild: true

```

There is also a task that can be used to sync the texts to the DB. You can run it via `dev/tasks/SyncLingoTask` .

### Usage

[](#usage)

Use the SilverStripe translation functions as you would normally use the Silverstripe translate function.

It will first search the regular yml-files for the entity. If it not exists there it will check if a Lingo translation entity exists in the DB. If it does the value of that will be cached and returned.

#### Use in php function

[](#use-in-php-function)

```

// Simple string translation
_t('LeftAndMain.FILESIMAGES','Files & Images');

// Using injection to add variables into the translated strings.
_t('CMSMain.RESTORED',
    "Restored {value} successfully",
    ['value' => $itemRestored]
);

```

#### Use in template

[](#use-in-template)

```
//with string

//with variable

```

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance7

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity66

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 ~221 days

Recently: every ~239 days

Total

8

Last Release

1206d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1150252?v=4)[Emil Berg](/maintainers/emilberg)[@emilberg](https://github.com/emilberg)

---

Top Contributors

[![emilberg](https://avatars.githubusercontent.com/u/1150252?v=4)](https://github.com/emilberg "emilberg (55 commits)")

---

Tags

languagetranslationymlsilverstripe

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/northcreationagency-silverstripe-lingo/health.svg)

```
[![Health](https://phpackages.com/badges/northcreationagency-silverstripe-lingo/health.svg)](https://phpackages.com/packages/northcreationagency-silverstripe-lingo)
```

###  Alternatives

[tractorcow/silverstripe-fluent

Simple localisation for Silverstripe

92421.6k26](/packages/tractorcow-silverstripe-fluent)[codezero/laravel-localized-routes

A convenient way to set up, manage and use localized routes in a Laravel app.

543638.1k4](/packages/codezero-laravel-localized-routes)[whitecube/lingua

A PHP language codes converter, from and to the most common formats (ISO, W3C, PHP and human-readable names).

441.2M15](/packages/whitecube-lingua)[boxblinkracer/phpunuhi

Easy tool to work with translation files for validation, exports, imports and more.

83225.2k17](/packages/boxblinkracer-phpunuhi)[badinansoft/nova-language-switch

A Laravel Nova package to switch language in your application

26506.4k1](/packages/badinansoft-nova-language-switch)[inpsyde/multilingual-press

Simply THE multisite-based free open source plugin for your multilingual websites.

2414.0k1](/packages/inpsyde-multilingual-press)

PHPackages © 2026

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