<?php dynamic_sidebar('header-right'); ?> </div><!-- .header-right --> <?php } elseif (current_user_can('edit_theme_options')) { ?> <div <?php hybrid_attr('header-right'); ?> > <p class="no-menu"> <?php _e('This is a widget area! It\'s perfect for a custom menu.', 'compass'); ?> <?php printf('<a class="button" href="%1$s">%2$s</a>', flagship_get_customizer_link(), __('Customize Now', 'compass')); ?> </p> </div><!-- .header-right --> <?php } remove_filter('wp_nav_menu_args', 'flagship_widget_menu_args'); remove_filter('wp_nav_menu', 'flagship_header_menu_wrap');
/** * Display a link to the customizer panel. * * @since 1.4.0 * @access public * @param $args array options for how the link will be formatted * @return void */ function flagship_customizer_link($args = array()) { echo flagship_get_customizer_link($args); }
// Translators: %s is the nav menu name. This is the nav menu title shown to screen readers. printf(_x('%s', 'nav menu title', 'compass'), hybrid_get_menu_location_name('primary')); ?> </span> <?php wp_nav_menu(array('theme_location' => 'primary', 'container' => '', 'menu_id' => 'primary', 'menu_class' => 'nav-menu primary', 'fallback_cb' => '', 'items_wrap' => '<div ' . hybrid_get_attr('wrap', 'primary-menu') . '><ul id="%s" class="%s">%s</ul></div>')); ?> </nav><!-- #menu-primary --> <?php } elseif (current_user_can('edit_theme_options') && !has_nav_menu('secondary')) { ?> <div class="header-right"> <p class="no-menu"> <?php _e("Ready to add your primary menu? Let's get started!", 'compass'); ?> <?php printf('<a class="button" href="%1$s">%2$s</a>', flagship_get_customizer_link(array('focus_type' => 'section', 'focus_target' => 'nav')), __('Add a Menu', 'compass')); ?> </p> </div><!-- .header-right --> <?php }