Feature #67909

Add a hook to DataHandler - localize - translateToMessage

Added by Goran Medakovic over 5 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend API
Target version:
Start date:
2015-07-04
Due date:
% Done:

100%

Estimated time:
PHP Version:
Tags:
Complexity:
easy
Sprint Focus:

Description

By adding a new hook to the localize function, translateToMessage processing we would be able to use external translation services and speed-up translation of the content and even add a custom transliteration functions that would handle various content transformations. I've already created an extension that uses this successfully.

Attaching a hook from extension would be as easy as (ext_localconf.php) :
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processTranslateToClass'][] = 'EXT:yourextension/class.tx_yourextension_tcemain.php:tx_yourextension_tcemain'

and then in the extension class:

class tx_yourextension_tcemain {
   function processTranslateTo_copyAction(&$content, $lang) {
        // Do something with content (translate, transliterate etc)
   }
}

Patch is attached.


Files

processTranslateToClass.diff (1.14 KB) processTranslateToClass.diff Goran Medakovic, 2015-07-04 10:41

Related issues

Related to TYPO3 Core - Bug #84844: Additional parameter(record field) needed for processTranslateTo_copyAction functionClosedRicky Mathew2018-04-24

Actions
#1

Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40920

#2

Updated by Gerrit Code Review over 5 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40920

#3

Updated by Gerrit Code Review over 5 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40920

#4

Updated by Alexander Opitz over 5 years ago

  • Target version changed from 6.2.14 to 7.4 (Backend)

Features won't go into 6.2 branch.

#5

Updated by Susanne Moog over 5 years ago

  • Target version changed from 7.4 (Backend) to 7.5
#6

Updated by Benni Mack about 5 years ago

  • Target version changed from 7.5 to 7 LTS
#7

Updated by Benni Mack about 5 years ago

  • Target version changed from 7 LTS to 8 LTS
#8

Updated by Gerrit Code Review about 5 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/40920

#9

Updated by Gerrit Code Review almost 4 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/40920

#10

Updated by Gerrit Code Review almost 4 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/40920

#11

Updated by Gerrit Code Review almost 4 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/40920

#12

Updated by Gerrit Code Review almost 4 years ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/40920

#13

Updated by Goran Medakovic almost 4 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
#14

Updated by Riccardo De Contardi about 3 years ago

  • Status changed from Resolved to Closed
#15

Updated by Tymoteusz Motylewski over 2 years ago

  • Related to Bug #84844: Additional parameter(record field) needed for processTranslateTo_copyAction function added

Also available in: Atom PDF