WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've made a menu in Wordpress backend with 3 levels depth. (4 main tabs with 2 sub level items)

I would like to know how I can get the number of tabs created automaticly and add this number to a class on the ul (i.e: .item-4)

Any ideas? I'm already using a custom Walker.


share|improve this question

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.