I make a wordpress theme using underscores and bootstrap.

I know that you can simply insert the menu in the sidebar.php before displaying the widgets

But I want to display the menu as a widget.

I will explain

What is now:

<section id="nav_menu-2" class="widget widget_nav_menu"> <h2 class="widget-title">Menu title</h2> <div class="menu-top-container"> <ul id="menu-top" class="menu"> <li id="menu-item-30" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-30"> <a href="http://#">О ΠΊΠΎΠΌΠΏΠ°Π½ΠΈΠΈ</a> </li> <li id="menu-item-31" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-31"> <a href="http://#">Акции</a> </li> <li id="menu-item-32" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-32"> <a href="http://#">ΠšΠ°Π±ΠΈΠ½Π΅Ρ‚</a> </li> </ul> </div> </section> 

I want to add bootstrap classes:

 <ul class="nav nav-pills nav-stacked"> <li><a href="#">Home</a></li> <li><a href="#">Profile</a></li> </ul> 

When I needed to customize the search form, I simply created the file searchform.php and it replaced the standard form.

What is the solution in this case?

  • Do you have two questions in one? 1) about the menu 2) by search form - is that so? - user33274
  • 1) Now I have a problem specifically with the menu. 2) I figured out the search form. - Zhag

0