How can we limit pdomenu submenu and change direction of submenu

[[!pdoMenu?
&parents=0
&level=4
&firstClass= &lastClass=
&outerClass=main-menu
&innerClass=sub-menu
&parentClass=parent
&hereClass=active
&scheme=full
&tpl=common.header.navitem
&tplOuter=common.header.navwrapper
&tplInner=common.header.innerwrapper
]]

Just to make sure I understand you correctly:

You want to limit the amount of menu items that are shown in a submenu and use a different order for those submenu items? Is that correct?

Do you want to do this only for one of your submenus or for the whole menu?

Yes right.
I just want to sort my submenu in desc order and main menu in asc.

I don’t think you can use different sorts for different parts of the menu tree.

I guess in your parent template, you have to check if it is the correct submenu and then run a nested [[pdoMenu? ...]] call instead of outputting the [[+wrapper]] placeholder to make this work.


With pdoMenu you can use the properties &sortdir and &limit to change the sorting order and limit the number of results.

Thank you for suggestion :slight_smile:

Here is an example from a similar case: