catchresponsive_primary_menu

Shows the Primary Menu.

Description

catchresponsive_primary_menu(); 

default load in sidebar-header-right.php


Usage

  1. if ( !function_exists( 'catchresponsive_primary_menu' ) ) { 
  2. require_once '/inc/catchresponsive-menus.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = catchresponsive_primary_menu(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/inc/catchresponsive-menus.php  
  1. function catchresponsive_primary_menu() { 
  2. ?> 
  3. <nav class="nav-primary search-enabled" role="navigation"> 
  4. <div class="wrapper"> 
  5. <h1 class="assistive-text"><?php _e( 'Primary Menu', 'catch-responsive' ); ?></h1> 
  6. <div class="screen-reader-text skip-link"><a href="#content" title="<?php esc_attr_e( 'Skip to content', 'catch-responsive' ); ?>"><?php _e( 'Skip to content', 'catch-responsive' ); ?></a></div> 
  7. <?php 
  8. if ( has_nav_menu( 'primary' ) ) {  
  9. $catchresponsive_primary_menu_args = array( 
  10. 'theme_location' => 'primary',  
  11. 'menu_class' => 'menu catchresponsive-nav-menu',  
  12. 'container' => false 
  13. ); 
  14. wp_nav_menu( $catchresponsive_primary_menu_args ); 
  15. else { 
  16. wp_page_menu( array( 'menu_class' => 'menu catchresponsive-nav-menu' ) ); 
  17.  
  18. ?> 
  19. <div id="search-toggle" class="genericon"> 
  20. <a class="screen-reader-text" href="#search-container"><?php _e( 'Search', 'catch-responsive' ); ?></a> 
  21. </div> 
  22.  
  23. <div id="search-container" class="displaynone"> 
  24. <?php get_Search_form(); ?> 
  25. </div> 
  26. </div><!-- .wrapper --> 
  27. </nav><!-- .nav-primary --> 
  28. <?php