Commit 46679815 authored by Frans Saris's avatar Frans Saris Committed by Wouter Wolters
Browse files

[BUGFIX] Use correct typoscript settings in ClickEnlargeViewHelper

The ClickEnlargeViewHelper receives typoscript settings in the extbase
format without the leading dots. The code called by the viewHelper
expects the typoscript syntax with the leadings dots.

This patch converts the settings array to a TypoScript array before
passing the settings to imageLinkWrap().

Change-Id: I19da35b10d079dddc19a18ecdff4ae8ebe1bdc9f
Resolves: #70317
Releases: master

Reviewed-by: default avatarDaniel Goerz <>
Tested-by: default avatarDaniel Goerz <>
Reviewed-by: default avatarJosef Glatz <>
Tested-by: default avatarJosef Glatz <>
Reviewed-by: Alexander Grein's avatarAlexander Grein <>
Tested-by: Alexander Grein's avatarAlexander Grein <>
Reviewed-by: default avatarMichael Oehlhof <>
Reviewed-by: Wouter Wolters's avatarWouter Wolters <>
Tested-by: Wouter Wolters's avatarWouter Wolters <>
parent aa2eafba
......@@ -14,6 +14,8 @@ namespace TYPO3\CMS\FluidStyledContent\ViewHelpers\Link;
* The TYPO3 project - inspiring people to share!
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Extbase\Service\TypoScriptService;
use TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer;
use TYPO3\CMS\Fluid\Core\ViewHelper\AbstractViewHelper;
use TYPO3\CMS\Fluid\Core\Rendering\RenderingContextInterface;
......@@ -69,7 +71,7 @@ class ClickEnlargeViewHelper extends AbstractViewHelper {
static public function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext) {
$image = $arguments['image'];
$configuration = $arguments['configuration'];
$configuration = self::getTypoScriptService()->convertPlainArrayToTypoScriptArray($arguments['configuration']);
$content = $renderChildrenClosure();
$configuration['enable'] = TRUE;
......@@ -82,4 +84,15 @@ class ClickEnlargeViewHelper extends AbstractViewHelper {
static protected function getContentObjectRenderer() {
return $GLOBALS['TSFE']->cObj;
* @return TypoScriptService
static protected function getTypoScriptService() {
static $typoScriptService;
if ($typoScriptService === NULL) {
$typoScriptService = GeneralUtility::makeInstance(TypoScriptService::class);
return $typoScriptService;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment