Actions
Bug #95833
closedHtmlParser throws exception in PHP 8.0
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2021-10-31
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
11
PHP Version:
8.0
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
When running the Crawler devbox with PHP 8.0 and TYPO3 11.5.1 I get the following error when opening the frontend in the browser.
PHP Warning: Undefined array key "fixAttrib" in /var/www/html/public/typo3/sysext/core/Classes/Html/HtmlParser.php line 916
if (!is_array($keepTags[$key]['fixAttrib'][$atName])) {
$keepTags[$key]['fixAttrib'][$atName] = [];
}
When fixing that with
if (!isset($keepTags[$key]['fixAttrib'][$atName]) || !is_array($keepTags[$key]['fixAttrib'][$atName])) {
$keepTags[$key]['fixAttrib'][$atName] = [];
}
I run into the next exception
PHP Warning: Undefined array key "range" in /var/www/html/public/typo3/sysext/core/Classes/Html/HtmlParser.php line 920
if ((string)$keepTags[$key]['fixAttrib'][$atName]['range'] !== '') {
$keepTags[$key]['fixAttrib'][$atName]['range'] = GeneralUtility::trimExplode(',', $keepTags[$key]['fixAttrib'][$atName]['range']);
}
And so it continues.
My devbox is based on:
bk2k/bootstrap-package 12.0.3
typo3/cms-introduction 4.4.1
this is tested with the dev-master from today (31.10.21)
I don't expect it to be something in my setup. But as it's not a TYPO3 pure, but has other components in it too, I can not exclude that possiblity.
Actions