Version 1.0.4-beta1
Release date 02.10.2019
Downloads 549
Views 908
Warning! This component requires PHP version 5.6 or higher! If your site uses PHP less than required, the installation of this package could break it.
Warning! This package requires MODX not less than 2.5 !


Language versions / satellites without contexts, with automatic translation of all fields of the resource + seo, and even the translation of lexicons — that I put in the name localizator .
<cut />
Why did I do this: I was not approached by a niraz, I kept one project for migx «localization» for a long time, but too it is not convenient, collected all the minuses that managed to reveal and solved them in its component.

Features
1. Creating pseudo-contexts «localization» (you can work together through site.ru/en/ and ch.site.ru)


2. The resource has a tab, where all standard fields of the resource + seo are filled, then at the push of a button this all can be translated into other languages, the content field for now only supports tiny mce rte.


3. For ease of use of lexicons, there are separate tabs on the component page where only the lexicon of the component is visible. There is also a choice of language. There is also automation of translation, one button click.


Localization of pdoTools
About work with pdoResources and pdoMenu did not forget, here's an example:
{'! pdoMenu' | snippet: [
'parents' => 0,
'leftJoin' => '{
"localizator": {
"class": "localizatorContent",
"alias": "localizator",
"on": "localizator.resource_id = modResource.id"
}
} ',
'select' => '{"localizator": "modResource. *, localizator. *, modResource.id"}',
        'where' => '{"localizator.key": "' ~ ('localizator_key' | option) ~ '"}',
]}
Totally, all the resource fields are replaced with the translated ones.

How to use
All fields of the resource are replaced by localized, except content, it is output through {$ _ modx-> resource.localizator_content} .

Settings
To automate the translation, you need api key for the Yandex translator, you can get it here: translate.yandex.ru/developers/keys and specify in the localizator_key_yandex setting, also what would the translator understand from which language to translate you need to specify the localization key in localizator_default_language

Cost
The component is completely free, did for my project, I think many will make life easier.
Send your thanks here: yasobe.ru/na/localizator or ask me for the card number in ms :)

Demo: s9431.h8.modhost.pro/ (bug with a link to the main, always throws on the «bare domain»)

1.0.4-beta1

  • Fixed error modWebLink resources
  • Fixed error tinymce_rte

1.0.4-beta

  • Fixed snippet Localizator
  • Fixed plugin Localizator
  • Fixed localizator.class.php
  • Added mse2_filters_handler_class
  • Added localization fields indexing in mSearch2 (by pavelgvozdb - https://modx.pro/howto/16466)

1.0.3-beta

  • Fixed snippet Localizator

1.0.2-beta

  • Added translate for migxtv fields (by nizart91)
  • Fixed localizatorcontent.class.php
  • Fixed snippet Localizator

1.0.1-beta

  • Added localization for tv fields (by nizart91)

1.0.0-beta

  • First release