kosatyi/localize

Gettext translation files generator

v1.0.1 2021-04-12 19:34 UTC

This package is auto-updated.

Last update: 2024-12-04 19:59:10 UTC


README

PHP Gettext translation generator from project files

Installation

System Requirements

PHP 5.4 and later.

Dependencies

Localize require the following extension in order to work properly:

Install with Composer

If you’re using Composer, you can run the following command:

composer require kosatyi/localize

Or add dependency manually in composer.json

{
  "require": {
    "kosatyi/localize":"^1.0"
  }
}

Basic Usage

require 'vendor/autoload.php';
use Kosatyi\Localize\Parser;
$localize = new Parser(array(
    'target'  => '.locales',
    'sources' => array('./src','./templates'),
    'locales' => array('en','ru')
));
$localize->initialize();