Great question — answering as the UphillTech team:
you can do this with out hooks . simply change the " name " attribute for the category input to " product_cat ". so remove the hook and change your code like this: <form role="search" method="get" action="<?php echo get_permalink( woocommerce_get_page_id( 'shop' ) ); ?>"> <div class="search-bar-select hidden-sm hidden-xs"> <strong textspan></span> <i></i> <select name="product_cat"> <option value="" class="search-bar-select-text"><?php _e('[:ru]Все категории[:ro]Toate categoriile') ?></option> <?php foreach(woo_category_list(FALSE) as $category) { ?> <option value="<?php echo $category->slug; ?>"><?php echo $category->cat_name; ?></option> <?php } ?> </select> </div> <div...
Full answer by webelizer: https://stackoverflow.stackexchange.com/a/40851228 (CC BY-SA 3.0).
Need it done for your business? UphillTech.