Woocomerce verison 9.0.2.
Thank you in advance.
]]>I’m using version 6.7.0
Can you please help me to solve the problem?
roberto
Thanks in advance,
Tony
Woocommerce categories and products appear on the same row, in the same ul element. I personally find this confusing and was looking for a way to separate them.
I found this code, which looks like a very clean solution.
// Remove subcategories from the product loop
remove_filter( 'woocommerce_product_loop_start', 'woocommerce_maybe_show_product_subcategories' );
// Add subcategories before the product loop with priority 5
add_action( 'woocommerce_before_shop_loop', 'cg_show_product_subcategories', 5 );
function cg_show_product_subcategories() {
$subcategories = woocommerce_maybe_show_product_subcategories();
if ( $subcategories ) {
echo '<ul class="products subcategories">', $subcategories, '</ul>';
}
}
Source: https://www.commercegurus.com/docs/shoptimizer-theme/products-subcategories-separate/
The listings pages look much better like this!
The problem is that on my site (I’m using the Astra free theme), the categories are now showing twice. In their new place (before the shop loop, just above the ordering filter options, which is actually perfect and should be their default place in my opinion), AND in the shop loop alongside with the products (the default place where they already were before).
Could someone help me find the way to prevent them to show a second time in the shop loop?
And what’s about make this a default behaviour (or at least an option) in Woocommerce?
]]>Hello all.
I am having a great deal of trouble with 2024 WP with regards to navigation menus and categories. I was able to do this in the past but I can’t with the new block editor system. This is probably due more to my lack of understanding about the nuts and bolts of WP than the new system.
I am trying to achieve a nav bar that looks like this (items below top line are sub and subsub categories of ‘Posts’ that I would like to appear as a drop down menu):
Home?Posts?Etc Etc
Explore Posts by Country Explore Posts by Category
Egypt Outdoors
Turkey Food
etc etc
To create the ‘Posts’ link in the navigation menu I went to settings/reading/you home page display/posts page/posts. What I am unable to do is proceed beyond this point, and work out how to create the ‘Explore Posts by Country’ and Explore Posts by Category’ submenus. I have created them as categories, but they are ‘just names’ at this point. I don’t know how to link them to the navigation menu. I have created all the subsub categories (names of countries, names of categories) underneath the Parent Categories ‘Explore…Country’ and ‘Explore…Category’ and assigned my posts to them.
If anyone could please help I would be very grateful.
Thanks in anticipation, Jim
]]>I am having a great deal of trouble with 2024 WP with regards to navigation menus and categories. I was able to do this in the past but I can’t with the new block editor system. This is probably due more to my lack of understanding about the nuts and bolts of WP than the new system.
I am trying to achieve a nav bar that looks like this (items below top line are sub and subsub categories of ‘Posts’ that I would like to appear as a drop down menu):
Home Posts Etc Etc
Explore Posts by Country Explore Posts by Category
Egypt Outdoors
Turkey Food
etc etc
To create the ‘Posts’ link in the navigation menu I went to settings/reading/you home page display/posts page/posts. What I am unable to do is proceed beyond this point, and work out how to create the ‘Explore Posts by Country’ and Explore Posts by Category’ submenus. I have created them as categories, but they are ‘just names’ at this point. I don’t know how to link them to the navigation menu. I have created all the subsub categories (names of countries, names of categories) underneath the Parent Categories ‘Explore…Country’ and ‘Explore…Category’ and assigned my posts to them.
If anyone could please help I would be very grateful.
Thanks in anticipation, Jim
]]>I want to modify the behavior of product category links in my WooCommerce store. Currently, when users click on a product category, they see a page displaying subcategories (ie “Cooling and Heating” > “Air cons” & “Heaters”). However, when they click on a subcategory, they’re taken to another page displaying further subcategories, if available (i.e “Cooling and Heating” > “Air cons” > “Inverter units” & “1HP units” & “Split units” and do one), instead of directly to the product listing page for that subcategory (i.e “Cooling and Heating” > “Air cons” > Page with all “Air cons” listings.
Thanks
]]>How to add subcategories grid before products grid in woocommerce store. By default only products are visible.
]]>This is what i created
Main category
sub category
sub category
Main category
sub category
And this is what i see in my wordpress post, taxonmy widgte
Main category
Main category
sub category
sub category
sub category