I’m running Genesis Framework on WordPress and I have to display a different top menu for logged in users and a different one for unregistered users (guests).
I created the 2 menus in the WP backend > Appearance > Menus:
top-menu1
forguests
top-menu2
forregistered users
Normally I’d have to just use this:
if( !is_user_logged_in() ){
wp_nav_menu( array( 'primary' => 'top-menu1' ) );
} else {
wp_nav_menu( array( 'primary' => 'top-menu2' ) );
}
Since this is Genesis though, I’d like you to point me to:
- what’s the equivalent of the
wp_nav_menu
function? - how do I register the 2 menus?
- what files do I have to modify?