Project

General

Profile

Actions

Feature #46448

closed

Add items for sectionIndex menu where pages loading content from other pages

Added by Christian Finkemeier about 11 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
Start date:
2013-03-20
Due date:
% Done:

100%

Estimated time:
PHP Version:
Tags:
Complexity:
no-brainer
Sprint Focus:

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.

Actions

Also available in: Atom PDF