Download the PHP package r3h6/form-translator without Composer

On this page you can find all versions of the php package r3h6/form-translator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package form-translator

Latest Stable Version TYPO3 12 TYPO3 11 Total Downloads Monthly Downloads

form_translator

This extension provides a backend module for translating TYPO3 form framework forms and a cli for creating a source xliff file for a given form.

Installation

Either from TYPO3 TER or through composer $ composer req r3h6/form-translator.

Integration

If you like use machine translation by LibreTranslate you must only configure an api host in the extension configuration. See available mirrors.

How it works

The extensions adds a translation file path to the *.form.yaml file when localize through the backend module.

Customized validation error messages are translated by overriding the form definition at runtime using the afterBuildingFinished hook from the form framework.

Upgrade

From v2 an TYPO3 v12

Rename language files prefixed with a locale like de_DE.locallang.xlf to the corresponding TYPO3 language de.locallang.xlf or setup a custom language.

From v2 an TYPO3 v11

No changes required.

Known issues

Transalte to English overrides the original form labels

Scenario: German is used as default language and your form definition labels are in German too.

When you translate a form to English, English will override your original labels even on the German version of your site.
You have following options:

  1. Create a (duplicated) German translation of the form
  2. Add the English locale without charset to the extension configuration typo3LanguageWhitelist

Background: Beginning with v12, TYPO3 uses the locale configured for the site to determine the language.
For English, TYPO3 uses the file named xyz.xlf, it does not load a file named en.xyz.xlf, but it does for en_US.xyz.xlf.

Resources

Develpment

Events

Name Description
AfterParseFormEvent Allows to change the translatable items of a form
FinalizeTypo3LanguagesEvent Allows to change the available languages

Local setup

Setup libretranslate:

docker run -ti --rm -p 5000:5000 -e LT_LOAD_ONLY='en,de' libretranslate/libretranslate

LibreTranslate host:

http://host.docker.internal:5000/

Contribution

Pull request are welcome!

Please note: I will not include other translation api's than LibreTranslate in this extension. If you need an other service, you can create your own by implementing TranslationServiceInterface.


All versions of form-translator with dependencies

PHP Build Version
Package Version
Requires php Version >= 8.1 < 8.4
softcreatr/jsonpath Version ^0.9
typo3/cms-core Version ^12.4 || ^13.4
typo3/cms-form Version ^12.4 || ^13.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package r3h6/form-translator contains the following files

Loading the files please wait ....