Created
August 9, 2017 04:52
-
-
Save anonymous/5e2063ef14efb06f2989cbe0937c3fb0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function clean_commerce_add_primary_navigation() { | |
?> | |
<div id="main-nav" class="clear-fix"> | |
<div class="container"> | |
<nav id="site-navigation" class="main-navigation" role="navigation"> | |
<div class="wrap-menu-content"> | |
<?php | |
wp_nav_menu( array( | |
'theme_location' => 'primary', | |
'menu_id' => 'primary-menu', | |
'fallback_cb' => 'clean_commerce_primary_navigation_fallback', | |
) ); | |
?> | |
</div><!-- .menu-content --> | |
</nav><!-- #site-navigation --> | |
<?php $search_in_header = clean_commerce_get_option( 'search_in_header' ); ?> | |
<?php if ( true === $search_in_header ) : ?> | |
<div class="header-search-box"> | |
<a href="#" class="search-icon"><i class="fa fa-search"></i></a> | |
<div class="search-box-wrap"> | |
<?php | |
if ( clean_commerce_is_woocommerce_active() ) : | |
get_product_search_form(); | |
else : | |
get_search_form(); | |
endif; | |
?> | |
</div><!-- .search-box-wrap --> | |
</div><!-- .header-search-box --> | |
<?php endif; ?> | |
</div> <!-- .container --> | |
</div> <!-- #main-nav --> | |
<?php | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment