Bug #24186
closedHTMLparser - fixAttrib.['class'].list does not assign first element, when attribute value not in list
100%
Description
I have the following configuration:
lib.parseFunc_RTE.externalBlocks.table.stdWrap.HTMLparser.tags.table.fixAttrib.class.list = contenttable, sofa1, sofa2, sofa3, sofa4
When a table has a class not in the list above, the result is not 'contenttable' as expected, but an empty class.
In class.t3lib_parsehtml.php line 827 the current code is:
if (count($newClasses)) {
$tagAttrib0[$attr] = implode(' ', $newClasses);
} else {
$tagAttrib0[$attr] = '';
}
I think that has to be:
if (count($newClasses)) {
$tagAttrib0[$attr] = implode(' ', $newClasses);
} else {
$tagAttrib0[$attr]=$params['list']0;
}
(issue imported from #M16542)