Download the PHP package transactpro/phalcon-translate without Composer
On this page you can find all versions of the php package transactpro/phalcon-translate. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package phalcon-translate
Phalcon Translation Module
How it works:
This translation module is designed to be able to store/access any key in/from database. All translation map is accessible at any time without spawning new queries. There are three steps to match your key in translation map:
- provided or default language
- fallback language
- key as it is
Example #1:
We have `test` key with value `Test value` in our translation map for English only.
When we will ask for `test` with language key (`en` is enabled as fallback language):
- en: `Test value`
- de: `Test value`
- ru: `Test value`
When we will ask for `test` with language key (without fallback language):
- en: `Test value`
- de: `test`
- ru: `test`
Example #2:
We have `test` key with value `Test value`/`Тестовое значение` in our translation map for English and Russian.
When we will ask for `test` with language key (`en` is enabled as fallback language):
- en: `Test value`
- de: `Test value`
- ru: `Тестовое значение`
- without: `Test value`
When we will ask for `test` with language key (without fallback language):
- en: `Test value`
- de: `test`
- ru: `Тестовое значение`
- without: `Test value`
Installation
Usage and Configuration
First of all you have to create translation table:
Set shared service translate
to your Dependency Injection
container, providing your translation model class name.
Example:
You can add filter to your Volt or Twig.
Example:
If your table (model) does not match to provided translation.sql
You can map your own columns as option set in third param array:
All versions of phalcon-translate with dependencies
PHP Build Version
Package Version
Requires
ext-phalcon Version
>=2.0
The package transactpro/phalcon-translate contains the following files
Loading the files please wait ....