Actions
Bug #97268
closedPage Layout without cols does not work with PHP 8.1
Status:
Closed
Priority:
Should have
Assignee:
Category:
Backend User Interface
Target version:
Start date:
2022-03-31
Due date:
% Done:
100%
Estimated time:
TYPO3 Version:
11
PHP Version:
8.1
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
PHP Runtime Deprecation Notice: explode(): Passing null to parameter #2 ($string) of type string is deprecated in /var/www/html/vendor/typo3/cms-core/Classes/Utility/GeneralUtility.php line 935
$result = explode($delimiter, $string) ?: [];
Triggered from /var/www/html/vendor/typo3/cms-backend/Classes/Controller/PageLayoutController.php line 592
$colPosArray = array_unique(GeneralUtility::intExplode(',', $this->colPosList));
The error occurs when the backend layout used does not contain colPos. We use this, for example, to display no colPos in SysFolders, since no content is usually maintained there. TSconfig for the backend layout looks like this:
mod.web_layout.BackendLayouts.empty { title = Empty config { backend_layout { colCount = 0 rowCount = 0 } } }
The issue seems not to occur in current main, as the effected line was changed as part of a breaking change and does not run into this error.
Actions