Add this code to functions.php. You can then use the shortcode [search_form], or whatever you choose to name it, in a menu. I used it in the navigation label field of a custom link.
function search_form_shortcode() {
return get_product_search_form(false);
}
add_shortcode('search_form', 'search_form_shortcode');
Related Posts:
- How can I define a custom template for woocommerce [products] shortcode? [closed]
- Search results don’t show products
- Shortcode with product catgory counter
- wc_get_product in a none woocommerce page
- How to search Woo Commerce products with punctuation in title?
- WooCommerce Multi-Currency shortcode not working
- Woocommerce wp-admin search products through custom meta value too
- if statement for search results
- shortcode to display woocommerce cart total
- Separeting product from post in search result
- Products Shortcode is Displaying Single Product Page Price for all Products [closed]
- How can I custom order the product display?
- Woocommerce custom search
- Woocommerce Shortcode custom orderby not working
- Change the Title Tag of Search Products Page
- WooCommerce orderby template disappears and not longer works on search page
- search customers in front end by billing data
- Override static method in WC_Shortcodes class (shortcode) [closed]
- Unable to pull in custom product attribute in shortcode [closed]
- Adding author option to [products] woocommerce shortcode
- Pass class to Woocommerce shortcode [relative_products] [closed]
- Can’t find a product by SKU
- Absolute search against wordpress api
- How can i access woocommerce order variables inside shortcode?
- override the default WooCommerce products search form
- porto theme pagination on woocommerce not working
- Create a Search Form that only Searches with WooCommerce Sale Products
- Call product search from custom hook
- Search doesn’t return anything
- edit URL of search result
- No Results in WooCommerce Product Search
- Woocommerce Multisite global search how to mod ajax function?
- I wan redirect link post search to search product woocommerce?
- How to filter result set in custom metaboxes?
- I want to show always 4 category boxes everytime in woocommerce
- Woocommerce: Search by custom attribute
- How to use products shortcode in taxonomy-product_cat with multiple columns?
- Why isn’t working WooCommerce session inside shortcode?
- Notice: Trying to get property of non-object in
- Shortcodes in billing fields doesn’t work
- How can I change my search form to bring up product results, not blog results
- woocommerce Shortcodes – Change display between mobile and Desktop
- How to check which shortcode is using my template?
- If YITH Wishlist page is set to the WooCommerce my-account endpoint, the endpoints stop working all together. Any solution?
- Is it possible to hide certain products from displaying in the search results
- Creating a shortcode with a variable (Woocommerce)?
- Trying to insert a div ID link into Woocommerce shortcode Pagination
- Woocommerce ajax search can’t work on mobile
- how should i get products based on tags in woocommerce
- Order by rating not works in wp_query
- Hide income in Woocomercer [closed]
- Hide tabs on woocommerce product editor for user role
- Woocommerce add_to_cart non-register visitor not working
- WooCommerce: The model of e-mail is displaying only the html, not css [closed]
- How to show loading spinner after click on add to cart button [closed]
- Authenticate user into wordpress via 3rd party system, both with the same domain
- How to get woocommerce subscription next payment date or date when subscription expires in woocommerce_subscription_renewal_payment_complete hook?
- Display Message if woocommerce coupon is not applicable to some items in the cart
- (Woocommerce) How to add a custom page between cart and checkout with a file upload field per product item in the cart?
- Force uppercase on some WooCommerce checkout fields input
- Display custom field without plugin in woocommerce
- How to output php between header and woocommerce container
- WooCommerce – How can I make single product gallery show two images on the slider at once?
- How to delete all customer user account that haven’t placed a single order?
- How do I hide ‘out of stock’ products in the admin ‘product’ page?
- Hide the prefix before the price of the product [closed]
- Add custom field to Woocommerce add new attribute / edit page
- woocommerce axios react
- Woocommerce hook on address field change [closed]
- Maintenance mode just for WooCommerce shop pages [closed]
- Custom email template for a specific product category
- Same request Mysql/Php not same result
- Conditional action hook
- Migrating data from Woocommerce to another webapp
- Options to develop a non-ecommerce catalog?
- wp_set_object_terms setting only first id from array
- I need to export all products and images but I don’t know which table the images are in
- Purchase/order statistics plugin for viewing per payment menthod?
- Displaying Woocommerce Product Attributes on single product page
- Categories on attribute archive pages
- How to solve `Error getting remote image` in woocommerce rest api script?
- How can I display all products from all categories on one page with woocommerce?
- Add username and password section in WooCommerce’s my account page
- How to change user role after login?
- WooCommerce free shipping twice a week
- Product overlapping header
- merge tabs in woocommerce
- How to import products to Woo Commerce given that WP All Import keeps timing out
- How to make a custom redirect in WooCommerce?
- Firstname and lastname greyout or hidden Billing details at next checkout like username is hidden [closed]
- How to use woo commerce login to authenticate code php pages?
- how to add custom reviews button in woocommerce order complete generated mail
- Click Count on Download a File
- How to add coupon expiry date into the followup emails?
- Not all strings are translated
- Custom Woocommerce checkout filed yields a Json error when validating [closed]
- How to display Woocommerce catagories
- eCommerce solution doesn’t want to display its shortcodes or any content where it’s set to [closed]
- Woocommerce hidden fields with meta keys and values. how?
- Conflict between Woocommerce Booking + Woocommerce Product Options [closed]