Sign up ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

By default if a user has not created say a footer or a top level menu then WordPress, in the case of the footer, will use default content like pages and so on to "create" a menu.

I don't want this to happen. I want to do something like:

if user has not set a menu for footer
   display a message telling them they should.
   display said menu.

How would I do this?

share|improve this question

1 Answer 1

check in footer if their any menu for their location

    if ( has_nav_menu( $location ) ) {
         //add your footer menu or do something
      //display a message telling them they should

Important Link:


share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.