Bug #71570
closedCE "Special Menus" > pages hidden in menu are always excluded
100%
Description
I noticed that when I use the Fluid Styled content "Special Menus" (for example "menu of selected pages"), the pages that are marked as "hide in menu" are excluded from the menu.
In the old CSC Menu built with HMENU this behavior could be reverted with includeNotInMenu = 1
please bring back this functionality because it was very useful (esp. on the sitemap)
I add a relation to #71311 because I think it is related (or even the same)
Updated by Daniel Goerz almost 9 years ago
- Assignee deleted (
Benni Mack) - Target version changed from 7 LTS to Candidate for patchlevel
Updated by Daniel Goerz almost 9 years ago
From #71731 (closed as duplicate) posted by Robert Heinig:
To solve this problem the view helper "ce:menu.list" within the partial
EXT:fluid_styled_content/Resources/Private/Partials/Menu/Type-3.html
could be called with attribute includeNotInMenu="1".
Updated by Johannes C. Laxander over 8 years ago
The same problem also relates CE Menu/Sitemap, type "Menu of subpages...", partial "Menu/Type-1.html":
To set the parameter "includeNotInMenu" in the fluid template is not a practical way, because you must create additional Templates when you will both menu/sitemaps with or without pages hidden in menu.
A better solution I think, is set "includeNotInMenu" in the properties of the content element.
Updated by Björn Jacob about 8 years ago
A fast workaround is to make us of the tt_content.layout field.
Create a new layout item¶
TCEFORM { tt_content { layout { altLabels { 4 = Menu - include not in menu } types { menu { addItems.4 = menu-includeNotInMenu } } } }
Improve partial¶
Copy your partial (for example Type-3.html and adapt code:
<html xmlns:f="http://typo3.org/ns/TYPO3/CMS/Fluid/ViewHelpers" xmlns:ce="http://typo3.org/ns/TYPO3/CMS/FluidStyledContent/ViewHelpers" data-namespace-typo3-fluid="true"> <f:section name="menuElement"> <f:if condition="{pages}"> <ul class="ce-menu ce-menu-3"> <f:for each="{pages}" as="page"> <ce:menu.section pageUid="{page.uid}" as="contentElements" type="header"> <f:if condition="{contentElements}"> <f:for each="{contentElements}" as="contentElement"> <li> <f:link.page pageUid="{page.uid}" section="c{contentElement.uid}"> {contentElement.header} </f:link.page> </li> </f:for> </f:if> </ce:menu.section> </f:for> </ul> </f:if> </f:section> <f:if condition="{data.layout} == 4"> <f:then> <ce:menu.list pageUids="{pageUids}" as="pages" includeNotInMenu="1"> <f:render section="menuElement" arguments="{pages: pages}"/> </ce:menu.list> </f:then> <f:else> <ce:menu.list pageUids="{pageUids}" as="pages"> <f:render section="menuElement" arguments="{pages: pages}"/> </ce:menu.list> </f:else> </f:if> </html>
Works for me for now but having a backend representation is nicer.
Updated by Gerrit Code Review almost 8 years ago
- Status changed from New to Under Review
Patch set 66 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 67 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 68 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 69 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 70 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 71 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 72 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 73 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 74 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 75 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 76 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 77 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 78 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 79 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 80 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 81 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 82 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 85 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Gerrit Code Review almost 8 years ago
Patch set 86 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/51065
Updated by Anonymous almost 8 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 80fec593237b4289fab597c7194d759d30325bf6.
Updated by filigivuji filigivuji over 5 years ago
How exactly did the mentioned changeset solve this issue?
I found out how to include pages hidden in menu e.g. in the "Menu Pages" content element in TYPO3 9.5 (see MenuPages.typoscript for reference):
tt_content.menu_pages.dataProcessing.10.includeNotInMenu = 1
However I don't see how you could set this specifically per content element instance.
Also I'm not sure if the current default of includeNotInMenu makes sense for menu_pages (which is supposed to be a menu of user-selected pages), since one might argue that if users select pages in the content element they want them to be shown regardless of whether the pages are being set to be hidden in menus.