Issue Bug Resolved

#105895Mountpoints are not evaluated correctly as subpages by TMENU.IFSUB settings

András Ottó 01/07/25, 09:20 updated 10/22/26, 16:55

Description

We discovered after a TYPO3 Upgrade to the 12.4 version that the MenuProcessor dataProcessor does not render submenus if there are only mount points on the next level.

Imagine the following structure:

- Home 1 > www.domain1.com
– Page 1A
Home 2 -> www.domain2.com
– Page 2A
– Page 2B -> MountPoint to Page 1A

In this case a very simple TypoScript like this:

page = PAGE
page.10 = HMENU
page.10 {
1 = TMENU
1 {
wrap =
    |

NO.wrapItemAndSub =
  • |

  • expAll = 1
    }
    2 < .1
    }

    renders the correct navigation:
    - Page 2A
    – Page 1A

    ———————-
    ISSUE:
    ———————-

    If you change the TypoScript like this:

    page = PAGE
    page.10 = HMENU
    page.10 {
    1 = TMENU
    1 {
    wrap =
      |

    NO.wrapItemAndSub =
  • |

  • IFSUB = 1
    IFSUB.wrapItemAndSub =
  • |

  • expAll = 1
    }
    2 < .1
    }

    The result displayed is only:
    - Page 2A

    And it is handled as a NO (it does not get the hasSub class), because the isSubMenu function inside the AbstractMenuContentObject class delivers false.
    This is because the “pid” for the mounted page (Home 1) is compared to the actual pid of the page (Page 2A) and this is no match of course.
    The isSubMenu check is not happening if there are no “SUB-States” defined, that is why the first example works.

    The MenuProcessor defines “SUB-States” automatically so it means that it can’t work.

    —————————-
    EDITORAL WORKAROUND
    —————————-

    If you put a non MountPoint page in the navigation the whole block will be rendered, because then the navigation element has at least one subpage recognised.

    I could reproduce this issue with a new, plain installation.

    Reviews 3

    Files 2

    History 610

    1. Tung Ngo commented <span data-processor="relativetime" data-value="2025-07-15T10:30:54+00:00" > 07/15/25, 10:30 </span>

      I would like to add that this also affected subpages of type Shortcut (TYPO3 v13.4.15). The patch provided by @just2b resolved the issue. This might be related with this patch.

    2. Bastian Holzem commented <span data-processor="relativetime" data-value="2025-08-26T15:24:42+00:00" > 08/26/25, 15:24 </span>

      Same issue with TYPO3 13 and TYPO3\CMS\Frontend\DataProcessing\MenuProcessor using includeSpacer = 1
      If there are only Mount Points under the Spacer the children are missing in the data record.
      If the first subpage is a normal page childen contains all subpages including the mount points

    3. Georg Ringer commented and changed status Under Review Resolved done 0 % 100 % <span data-processor="relativetime" data-value="2026-10-22T16:55:14+00:00" > 10/22/26, 16:55 </span>

      Applied in changeset commit:caf8287e338ef047c8291b5d02546a585f86567f.