Project

General

Profile

Actions

Bug #99198

open

MenuProcessor returns wrong menu

Added by Oliver Schmidt over 1 year ago. Updated over 1 year ago.

Status:
Needs Feedback
Priority:
Should have
Assignee:
Category:
Fluid Styled Content
Target version:
-
Start date:
2022-11-25
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
12
PHP Version:
8.1
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Hello together,
in our pagetree we use folders in rootline to organize our multidomain typo3 instance:

- domain[0] (folder)
-- subdomain[0].domain[0] (page site_root)
-- subdomain[1].domain[0] (page site_root)
- domain[1] (folder)
-- subdomain[0].domain[1] (page site_root)
-- subdomain[1].domain[1] (page site_root)
...

At TYPO3 Version 11 the MenuProcessor returned a menu based on site_root and included only pages of the correct domain. At TYPO3 Version 12 the MenuProcessor returns a menu based on pid 0 with all root pages.

  dataProcessing {
    10 = TYPO3\CMS\Frontend\DataProcessing\MenuProcessor
    10 {
      levels = 4
      as = mainnavigation
    }
  }

At TYPO3 Version 11 the var leveluid:0 returned the id of site_root. At TYPO3 Version 12 the var leveluid:0 returns the folder id.
Is this a bug, or the new intended behavior? If it is intended, is there a workaround to use folders as described above?

Thank you. Greetings
Oliver


Files

Menu.JPG (34.2 KB) Menu.JPG MenuProcessor Output at TYPO3 12 if site_roots are in folder Oliver Schmidt, 2022-11-28 06:34
MenuAsExpected.JPG (26.5 KB) MenuAsExpected.JPG MenuProcessor Output at TYPO3 12 if site_roots are at root Oliver Schmidt, 2022-11-28 06:55

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #93924: MenuProcessor does not working correctly when doktype folderClosed2021-04-14

Actions
Actions #1

Updated by Stefan Bürk over 1 year ago

SysFolders should be normally not included, same as BE User Section. Did you by any chance set excludeDoktypes ? If yes, this got not merged. So add 6 + 254 along your other to be excluded doktypes.

Otherwise this should not happen -> see https://forge.typo3.org/issues/93924

If not, it's maybe another issue. However, I don't get that with leveluid:0 ... you do not use it in the menu processor definition.

Actions #2

Updated by Stefan Bürk over 1 year ago

  • Related to Bug #93924: MenuProcessor does not working correctly when doktype folder added
Actions #3

Updated by Stefan Bürk over 1 year ago

  • Status changed from New to Needs Feedback

Updated by Oliver Schmidt over 1 year ago

The SysFolders aren't the problem. They are not included as expected.

Test case 1: Homepages with site_root are at root level (pid 0)
- Everything works properly and as expected
- Menu contains the subpages of the homepage of current site (see screenshot)
- The values of the vars leveluid:0 and site:rootPageId are the same, uid of homepage

Test case 2: Homepages with site_root are in folders
- Root of menu is not correct
- Menu contains homepages of both sites at first level (see screenshot)
- The values of the vars leveluid:0 and site:rootPageId differ, uid of folder and uid of homepage

Hope this information is helpful.

Actions #5

Updated by Oliver Schmidt over 1 year ago

My current workaround for menu is:

  dataProcessing {
    10 = TYPO3\CMS\Frontend\DataProcessing\MenuProcessor
    10 {
      special = directory
      special.value.data = site:rootPageId
      levels = 4
      as = mainnavigation
    }
  }

and to use site:rootPageId instead if leveluid:0.

Actions

Also available in: Atom PDF