Make WordPress Core

Opened 16 years ago

Closed 12 years ago

Last modified 12 years ago

#16301 closed enhancement (fixed)

set limits to nesting of menus

Reported by: alxndr Owned by:
Priority: normal Milestone: 3.0
Component: Menus Version:
Severity: normal Keywords:
Cc: Focuses:

Description

It would be great to be able to limit/control the nesting depth of menus. I'm using menus to let my editors control where posts show up in various spots in our theme, and don't want them to accidentally nest a link deeper than it should be.

Change History (3)

#1 @nacin
16 years ago

  • Keywords 2nd-opinion added; menus nesting submenus removed
  • Milestone Awaiting ReviewFuture Release
  • Type feature requestenhancement

Currently, nesting depth is abstracted to a JavaScript variable, which should be accessible at the JS level. You can do that for now, but there's no guarantee we won't break that in a future release.

I would not mind it if this variable can be made accessible through a filter in PHP (and thus via localize()).

#2 @chriscct7
12 years ago

  • Keywords close added; 2nd-opinion removed
  • Resolutionduplicate
  • Status newclosed

There's a depth parameter which can be used to limit menu depth on wp_nav_menu. Support for this was added with the introduction of wp_nav_menu in #11817

#3 @DrewAPicture
12 years ago

  • Keywords close removed
  • Milestone Future Release3.0
  • Resolution duplicatefixed

The 'depth' argument was added in [13802], see #11817.

Note: See TracTickets for help on using tickets.