E
E
Evgeniy Skorobogatov2018-07-23 22:36:13
WordPress
Evgeniy Skorobogatov, 2018-07-23 22:36:13

What's wrong with Secondary menu on WooCommerce product card page?

Weird situation.. Creating a menu

<?php
        wp_nav_menu(array(
          'theme_location' => 'sb_menu',
          'walker'         => new My_Secondary_Nav_Menu_Walker,
          'container'      => false,
          'menu_id'        => 'secondary-nav',
          'menu_class'     => 'secondary-nav',
        ));
      ?>

where class My_Secondary_Nav_Menu_Walker extends Base_Nav_Menu_Walker
On all pages of the site with a menu, everything is fine, but on the product card page (single-product.php), the class is no longer taken into account and the menu theme disappears .. can anyone come across something like this?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question