Feature #46448
closedAdd items for sectionIndex menu where pages loading content from other pages
100%
Description
I wanted to display a sectionIndex menu for a page that loads its content from another page via "content_from_pid". This is not possible yet.
To fix this issue, i added a few lines to the sysext/cms/tslib/class.tslib_menu.php file at line 840:
$basePageRow=$this->sys_page->getPage($this->id); if (is_array($basePageRow)) { + if ($basePageRow['content_from_pid']) { + $allowContentFromPid = isset($this->mconf['sectionIndex.']['content_from_pid.']) + ? $this->parent_cObj->stdWrap($this->mconf['sectionIndex.']['content_from_pid'], $this->mconf['sectionIndex.']['content_from_pid.']) + : $this->mconf['sectionIndex.']['content_from_pid']; + if ($allowContentFromPid) { + $selectSetup['pidInList'] .= ','.$basePageRow['content_from_pid']; + } + } $res = $this->parent_cObj->exec_getQuery('tt_content', $selectSetup);
It should be nice, if this patch could be applied to further versions of TYPO3.
Updated by Nico de Haen about 10 years ago
- Target version set to 6.2.0
Hi Christian,
I just have the same problem and I'm trying to migrate your patch to the current master.
But I don't understand how your $allowContentFromPid is implemented. The $this->mconf['sectionIndex']['content_from_pid'] is never set, no matter what configuration I try and so $allowContentFromPid is always NULL.
Can you explain this part? Then I would provide a patch to Gerrit.
regards,
Nico
Updated by Christian Finkemeier about 10 years ago
You have to add a boolean configuration flag, to enable this feature. E.g.
1 = TMENU 1 { sectionIndex = 1 sectionIndex.content_from_pid = 1 ... }
Updated by Gerrit Code Review about 10 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/27995
Updated by Gerrit Code Review over 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review over 9 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review about 9 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review about 9 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review almost 9 years ago
Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review almost 9 years ago
Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review almost 9 years ago
Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review almost 9 years ago
Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/27995
Updated by Gerrit Code Review almost 9 years ago
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/39381
Updated by Nico de Haen almost 9 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 969f75063a5d63c3b7f4aae1c2e52f25ecba7e5d.
Updated by Riccardo De Contardi over 6 years ago
- Status changed from Resolved to Closed