WooCommerce – Products Advanced Search plugin allows you to add an advanced search form for WooCommerce Products. With this form you can search products by name, category, price, dimensions attributes or custom attributes. You can customize the form and choose what fields do you want to appear in this form.
Form can be integrated in your site using a short-code in a page, as widget in a sidebar or as template tag in a template.
- Unzip ‘pc-woo-advancedsearch.zip’ and upload folder ‘pc-woo-advancedsearch’ to the ‘/wp-content/plugins/’ directory.
- Activate the ‘PluginsCode – WooCommerce Products Advanced Search’ plugin through the ‘Plugins’ menu in WordPress admin
Go to WordPress administration, Settings -> Advanced Search Options and configure your form
You have three options to integrate the form in your site:
- Include form in a page:
If you want to include search form and search results in one of you pages then you must to edit that page or create a new one and add this short code [pcw_search].
Availabe options for this shortcode are: items_per_page, columns, orderby, order.
Example: [pcw_search items_per_page=12 orderby=’date’ order=’desc’]
- Add widget in a sidebar
If you want to have the search form in your sidebar the you must go to WordPress administration -> Appearance -> Widgets and drag ‘WooCommerce Products Advanced Search Form’ widget to a sidebar. There you must specify the page where search results will be listed. You can create an new page for to show search results or can select an existing page
- Include search form in a template
<?php echo pc_woo_search_form_html(12, 4, ‘date’, ‘desc’); ?>
– 12 is number of results items in page
– 4 is number of results columns
– ‘date’ is order by parameter
– ‘desc’ is order direction
You can overrite search form styles in style.css file from your theme.
If you have problems installing or using this plugin, or any questions, please do not hesitate to contact us