WooCommerce
94Everything you need to launch an online store in days and keep it growing for years. From your first sale to m...
Simple solution to hide specific categories in you woocommerce shop main page i.e. domain.com/shop This plugin was based on WC Hide Categories On Shop …
Hide Categories On Shop Page is a free WordPress plugin designed for WooCommerce users. It allows you to hide specific product categories from the main shop page by saving category slugs in the WooCommerce settings. The plugin requires categories to be displayed, which can be configured through the WordPress Customizer.
This plugin is suitable for those who want to customise the visibility of product categories on their shop page, particularly if they have a specific layout or design in mind. Users with coding knowledge can also modify the plugin's PHP file for additional customisation options.
Best for: WooCommerce store owners looking to customise category visibility.
What it does well
Where it falls short
Hide Categories On Shop Page provides a straightforward solution for managing product category visibility, though it may require technical skills for full utilisation.
WMEric's own description of Hide Categories On Shop Page, lightly tidied.
This free WooCommerce extension permits you to hide categories on your shops main page.
For this you have to save the categories with ‘,’ seperated in woocommerce > settings > products tab section.
In order for this to work you have to have Categories displayed. This can be set via Customizer. Appearance > Customize > WooCommerce > Product Catalog.
“Choose what to display on the main shop page.” Select Show categories as seen in the Screenshot below.
For users who has a different/custom page for their shop you can edit the wc-hide-categories.php file
Find line # 127 and remove //
//$mwd_opt4 = in_array( 'product_cat', $taxonomies ) && ! is_admin() && is_page('YOUR_PAGE_SLUG'),
Then find line #129 /*|| $mwd_opt4*/
Change to
|| $mwd_opt4
To remove products from those categories find line 160
// Uncomment the function below if you also want those products hidden
/*
add_action( 'woocommerce_product_query', 'mwd_hwcosp_remove_product_in_cat' );
function mwd_hwcosp_remove_product_in_cat( $q ) {
//hwcosp_global is the databse row entry
$opt_terms = get_option('hwcosp_global');
// Processes our users data to the way we want it from above
$data = mwd_hwcosp_comma_separated_to_array($opt_terms);
$tax_query = (array) $q->get('tax_query');
$tax_query[] = array(
'taxonomy' => 'product_cat',
'field' => 'slug',
'terms' => $data, // Set Category Slug which products not show on the shop and Archieve page.
'operator' => 'NOT IN'
);
$q->set( 'tax_query', $tax_query );
}
*/
The code is well documented so its easy to find what part you are looking for
If you have any question please ask in the support forum, Thanks
Other plugins for selling online.
Everything you need to launch an online store in days and keep it growing for years. From your first sale to m...
Top-rated antispam for contact forms, comments, WooCommerce, eCommerce, and login. No CAPTCHAs, no friction, j...
Weight based shipping methods for WooCommerce. Flexible shipping with table rate rules by cart weight and orde...
Every store loses sales to cart abandonment. But with Cart Abandonment Recovery for WooCommerce, you can win t...
Germanized extends WooCommerce to become a legally compliant shop for the german market. Must Have for every g...
🤩 Make popups & optin forms to get more email newsletter subscribers, leads, and sales - #1 most popular...