Project

General

Profile

Actions

Bug #64176

closed

generateTtContentDataArray(null) breaks backend

Added by Anonymous almost 10 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2015-01-07
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
4.5
PHP Version:
5.3
Tags:
Complexity:
Is Regression:
Yes
Sprint Focus:

Description

The commit ebdd15ea62115329eb324ac29e5400e5806c01bf (4.5.35) breaks the page module in case the attribute $rowArr of the new function generateTtContentDataArray() is null instead of an array.

Unfortunately I haven't had any opportunity yet to debug it any further to find out why the $rowArr is null in my case. But maybe Nicole already knows why ;-)

https://git.typo3.org/Packages/TYPO3.CMS.git/blobdiff/021526a7242da1a6e8056b6cabf8230020ef3093..ebdd15ea62115329eb324ac29e5400e5806c01bf:/typo3/sysext/cms/layout/class.tx_cms_layout.php?ds=sidebyside


Files

tx_cms_layout.patch (883 Bytes) tx_cms_layout.patch Anonymous, 2015-01-08 14:56
Actions #1

Updated by Anonymous almost 10 years ago

Ok, here are my debugging results.

In our case $this->tt_contentConfig['cols']) was containing an empty string which resulted in an 1 item containing array $cList = array(0 => '') after being exploded. $this->tt_contentConfig['cols']) was empty because of a TSconfig snippet mod.SHARED.colPos_list = 99, which removed all the tt_content column in page module. (Background: other tables have been added to page view, so we wouldn't need any tt_content columns!)

Up until 4.5.35 this work just fine. In order to get this working again I suggest to use t3lib_div::trimExplode() instead of explode(). See attached patch file for 4.5.x.

Actions #2

Updated by Oliver Hader almost 9 years ago

  • Status changed from New to Needs Feedback

Is that still an issue with current 6.2 and 7.6 installations?

Actions #3

Updated by Jigal van Hemert over 8 years ago

  • Status changed from Needs Feedback to Accepted

By reading the code the change from explode to trimExplode seems valid. explode(',', '') results in array(0 => '') (an array with the string that should be exploded)
This is not what the rest of the code expects. An empty array is a better value as it will prevent foreach loops from doing anything.

Actions #4

Updated by Nicole Cordes over 8 years ago

Problem was solved in 7.4.0 with patch https://review.typo3.org/41768/

Actions #5

Updated by Gerrit Code Review over 8 years ago

  • Status changed from Accepted to Under Review

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/49000

Actions #6

Updated by Nicole Cordes over 8 years ago

Following PageTS I needed to reproduce the error:

mod.SHARED.colPos_list = 99
mod.web_layout.tt_content.colPos_list = 99
TCEFORM.tt_content.colPos.removeItems = 0, 1, 2, 3
Actions #7

Updated by Nicole Cordes about 8 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #8

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF