Created
April 13, 2014 18:47
-
-
Save BoweFrankema/10596814 to your computer and use it in GitHub Desktop.
WordPress Language Check
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
<?php | |
$currentlang = get_bloginfo('language'); | |
?> | |
<nav class="collapse navbar-collapse" role="navigation"> | |
<?php if($currentlang=="en-US"):?> | |
<?php | |
if (has_nav_menu('primary_navigation')) : | |
wp_nav_menu(array('theme_location' => 'primary_navigation', 'menu_class' => 'nav navbar-nav navbar-right')); | |
endif; | |
?> | |
<?php elseif($currentlang=="nl-NL"): ?> | |
<?php | |
if (has_nav_menu('primary_navigation_nl')) : | |
wp_nav_menu(array('theme_location' => 'primary_navigation_nl', 'menu_class' => 'nav navbar-nav navbar-right')); | |
endif; | |
?> | |
<?php endif; ?> | |
<?php | |
if ( function_exists( 'bp_is_member' ) ) { | |
get_template_part( 'buddypress/parts/bp-member-nav' ); | |
} | |
?> | |
</nav> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment