get_nav_menu_at_primary_location example


    private static function get_fallback_classic_menu() {
        $classic_nav_menus = wp_get_nav_menus();

        if ( ! $classic_nav_menus || is_wp_error( $classic_nav_menus ) ) {
            return null;
        }

        $nav_menu = static::get_nav_menu_at_primary_location();

        if ( $nav_menu ) {
            return $nav_menu;
        }

        $nav_menu = static::get_nav_menu_with_primary_slug( $classic_nav_menus );

        if ( $nav_menu ) {
            return $nav_menu;
        }

        
Home | Imprint | This part of the site doesn't use cookies.