#76029Regex in ExtensionManagementUtility::executePositionedStringInsertion is broken if you want to insert after a palette
Description
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes('pages', 'myfield', '', 'after:description');
The field “description” is part of the palette “metatags” so $positionName in ExtensionManagementUtility::executePositionedStringInsertion() is “—palette—;;metatags”. This is modified to “—palette—;[^;]*;metatags” and then escaped with “preg_quote($positionName, ‘/’)”. And then the preg_replace doesn’t work.
$positionName should be first quoted and then extended.
This was intruduced in https://forge.typo3.org/issues/75830.
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.