Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace deprecated Hook t3lib_parsehtml_proc.php:transformation #214

Open
kevin-appelt opened this issue Feb 1, 2023 · 3 comments
Open
Assignees
Labels
php PHP related task TYPO3 v12

Comments

@kevin-appelt
Copy link

The hook "t3lib/class.t3lib_parsehtml_proc.php->transformation" will be removed in TYPO3 v12.
https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/11.2/Deprecation-92992-HookT3libclasst3lib_parsehtml_procphptransformation.html

Environment

  • TYPO3 version: 11.5.22
  • PHP version: 8.1
  • Extension version: 11.0.6
@magicsunday magicsunday added the php PHP related task label Feb 1, 2023
magicsunday added a commit that referenced this issue Feb 3, 2023
magicsunday added a commit that referenced this issue Feb 3, 2023
@magicsunday magicsunday self-assigned this Feb 3, 2023
@prdt3e
Copy link
Contributor

prdt3e commented Jun 28, 2023

@sk-foresite has that in her version (for 12) via the t3lib/class.t3lib_tcemain.php solved.
it will not work.
I looked at the core.
It should now be resolved via the entryHTMLparser_db.

RTE.default.proc.entryHTMLparser_db = 1
RTE.default.proc.entryHTMLparser_db.tags.img{
current = 1 // always = 1
preUserFunc // userFunc = Netresearch\RteCKEditorImage\Controller.......
}

I think it will go in that direction.

@prdt3e
Copy link
Contributor

prdt3e commented Jun 28, 2023

@sypets #188

@prdt3e
Copy link
Contributor

prdt3e commented Jul 3, 2023

We have 2 options:
1.
as individual attributes or maybe just: data-htmlarea-file="{json}"

RTE.default.proc.entryHTMLparser_db = 1
RTE.default.proc.entryHTMLparser_db {
    tags {
        img.fixAttrib.src.userFunc  = Netresearch\RteCKEditorImage\Database\RteImagesDbHook->transform_rte
        img.fixAttrib.width.userFunc  = Netresearch\RteCKEditorImage\Database\RteImagesDbHook->transform_rte
        img.fixAttrib.height.userFunc  = Netresearch\RteCKEditorImage\Database\RteImagesDbHook->transform_rte
        img.fixAttrib.style.userFunc  = Netresearch\RteCKEditorImage\Database\RteImagesDbHook->transform_rte
        img.fixAttrib.data-htmlarea-file-uid.userFunc  = Netresearch\RteCKEditorImage\Database\RteImagesDbHook->transform_rte
  }
}

or 2: HTMLSanitizer

$GLOBALS['TYPO3_CONF_VARS']['SYS']['htmlSanitizer']['rtehtmlarea_images_db'] = \Netresearch\RteCKEditorImage\Sanitizer\RteImagesDbHook::class;

what do you mean?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
php PHP related task TYPO3 v12
Projects
None yet
Development

No branches or pull requests

4 participants