Overriding wp_nav_menu default arguments
If you want the options to be extensible by developers, just add a custom filter to the output: wp_nav_menu( apply_filters( ‘wpse119371_nav_menu_args’, array( ‘theme_location’ => ‘primary’, ‘container’ => false, // etc. ) ) ); Then, a developer merely has to add a filter callback: function wpse119371_filter_nav_menu_args( $args ) { // Modify $args $args[‘container’] => ‘div’; // … Read more