Localization

Control Panel
Version 2.0.0-beta1+
2 min read

Meerkat 2 builds on the localization framework first introduced in Meerkat 1.5.0. Language strings in the Statamic Control Panel may be customized, translated, or replaced entirely. Missing translation strings will default to English in the Control Panel (to prevent the translation keys from appearing).

Language Files

At the time of writing, the following language files are available:

Language Files Description
actions.php Contains language strings for all the actions in the Control Panel.
codes.php Maps error codes to another file's language string.
display.php Contains language strings for various headers, status messages, etc.
errors.php Contains language strings for error messages displayed in the Control Panel.
fields.php Provides language strings for CSV export headers.
filters.php Provides language strings for the various filters that appear in the Control Panel.
general.php Provides language strings for general items and branding.

Solution Providers

Meerkat 2 introduces a new built-in help system surrounding the use of error codes. Each provided solution may also be translated into other languages. The default solution files may be found in the following Meerkat source directory:

resources/
├── solutions/
|   ├── en/

The naming convention for solution files is:

code-<ERROR_CODE>.md

For error code 01-005, the file name would become code-01-001.md. Windows specific solution files can be created by prefixing the file with win.:

# A general solution provider:
code-01-001.md

# A Windows specific solution provider:
win.code-01-001.md

Solutions may also be viewed through command line utilities. To provide a solution formatted for console output, prefix the solution file with cli.:

# A general console solution provider:
cli.code-01-001.md

# A Windows specific console solution provider:
cli.win.code-01-001.md
Not Fully Implemented

Solution providers are not fully implemented throughout the system. More information will come soon.