Check language in header and display menu conditionally
-
Hi,
I was wondering if it is possible to check for the language in the header.php and display different menus conditionally:
<?php if( //language is English ): ?> <?php ubermenu( 'main' , array( 'theme_location' => 'primary_nav' ) ); ?> <?php else if( //language is Spanish ): ?> <?php ubermenu( 'main' , array( 'theme_location' => 'primary_nav___es' ) ); ?> <?php endif; ?> <?php else: ?>
I just don’t know what code to use to check for the language in the header.php if it is even possible. Any help would be greatly appreciated.
Thanks!
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Check language in header and display menu conditionally’ is closed to new replies.