The solution is quite simple. I copied single-product.php
from woocommerce/templates
and modified it so loop starts before before_main_content hook:
get_header( 'shop' ); ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php
/**
* woocommerce_before_main_content hook.
*
* @hooked woocommerce_output_content_wrapper - 10 (outputs opening divs for the content)
* @hooked woocommerce_breadcrumb - 20
*/
do_action( 'woocommerce_before_main_content' );
?>
That way it works fine, all functionalities are maintained.
Related Posts:
- Attach a Custom Post Type to a Woocommerc product as a variation or add-on [closed]
- Exclude a term of a taxonomy with a custom post type in a search
- If on term-page -> get the current term?
- How to solve suspected memory issue in custom WordPress loop?
- Query for posts from any post type but only add instock products
- Custom Taxonomy Breadcrumb Navigation
- WooCommerce – Show orders for a specific product ? [closed]
- Set meta_query only for specific post type
- get_terms won’t display product_cat or any other custom taxonomies when specified
- Get the posttype of a taxonomy/term
- Woocommerce query specific product from specific category
- Problem adding column to WC Subscription [closed]
- How to determine if custom post type showing on archive templates
- Create custom post type on successful woocommerce order [closed]
- Custom post type not displayed in breadcrumbs on archive page
- how to get URL of media uploaded to WordPress via media_handle_sideload()
- How to display product subcategories into my custom post type single page
- Get post from custom post type order by two taxonomies
- changing meta value and meta key of price field
- Woocommerce search pagination not working
- WooCommerce Customer Role Delete Custom Post Type
- WooCommerce sort products by the actual product width(not the shipping width)
- Manage custom post type in woocommerce /my-account/ page
- Woocommerce custom field search in custom post type [closed]
- Modifying custom post type created by WooCommerce
- Hide a widget inside a div on specific type of post
- Allow add new post access to custom post but not wp post for some role
- How to Get WordPress custom post data in WooCommerce product meta panel? [closed]
- Display Woocommerce Orders for specific author [closed]
- Parent Page and Breadcrumb URL’s for Custom Post Types Not Working
- Breadcrumb Not Linking to the Correct Custom Post Type Index Page(s)
- Sort posts in loop by the WooCommerce Membership of the author
- How to set up Custom Post Type archive page as Front page
- Copy order items with metadata between orders – Woocommerce
- Update Post Status On Woocommerce Payment Complete
- Get all post from a post type
- Custom Post Type to replace Woocommerce products – page not found error
- CPT as Product in WooCommerce
- Change permalink for custom_post_type using custom_post_meta (woocommerce)
- Using breadcrumb to return from single-page to list
- Blank search results on custom search
- Get Terms from Custom Taxonomy and Current Post
- Custom Post Type and Breadcrumbs Conflict
- Problem retrieving informations and displaying desired structure with custom post type and taxonomy
- Is it a connection or relationship between 2 custom post types?
- Multiple categories assigned to a single product breaking the breadcrumb
- Link custom post type to parent page and show in slug / breadcrumb
- Custom Post type to Woocommerce Product type
- Title and URL Error in Breadcrumb Navigation for Custom Post Types
- How to display related posts using the same taxonomy for custom types (WordPress, Pods, Woo)
- Post template with breadcrumb needs to show page navigated from
- How to display custom field in product description?
- Add two custom product type
- Duplicate the “Orders” list on Admin Page
- What’s the best way to do this: inquiry/ticket system?
- Sudden 404 pages on product category archives
- WordPress shortcode to pull product post data
- ‘Simple’ Reservation System
- Change display of product price on product show page only
- edit.php all post not working
- How to show link to product in custom fields?
- add action save post type and update post meta woocommerce
- WooCommerce – Custom related product (Spareparts)
- Convert attribute woocommerce terms (taxonomy terms) in posts of custom post type
- WooCommerce change
- WooThemes – Vendors / Bookings – Allow Vendors to manage resources
- Search in multiple specific post types
- Custom post type archive false is not compatible with breadcrumbs
- woocommerce post_type conflict with existing post type
- Custom Taxonomy not working front side Woocommerce
- Breadcrumb that shows multiple custom taxonomies
- Custom Taxonomy is disabled on Edit page
- CPT or Custom Table for Repository of Serial Numbers
- Get Non-Paginated Index of Post in Paginated Query
- Complex strcuture as CPT or taxonomy for use in woocommerce product variations [closed]
- Custom Search Template for Custom Post Types
- How to retrieve taxonomy terms of the current custom post?
- how do I create a breadcrumb to work with multiple custom taxonomies
- WP_Query wooCommerce category
- WooCommerce – Complete Order when an action occurs
- How to manage a bookstore
- Issue On Listing Woocommerce Parent Tag List
- custom post type breadcrumb error when has_archive = false
- Create a WordPress Database query to find users who purchased specific product through WooCommerce [closed]
- How can I list all the categories under a Custom Post Type (taxonomy)?
- I have a CPT that have menu_order enabled, how can I make the menu_order values unique so it won’t have duplicates
- How do you remove slug altogether from custom post type?
- Custom Post type in Author.php
- Custom Post hierarchical to custom taxonomy
- Displaying Custom Posts on a Page
- API Rest Custom Post Type doesn’t return all data
- Apply Post Class to Custom Post Type
- Problems making shortcode with custom post types and taxonomy
- WYSIWYG on custom meta boxes while disabling main editor?
- Set up a WP Cron scheduled event to update calculated ACF field
- set object terms after some some time of published post – functions.php
- How to use multiple Meta Field from CPT as Post permalink
- Populate metabox dropdown with post title from another Custom Post Type (issues with wp_reset / global $post)
- how to show perticular category posts in custome page
- Assign a tag to custom post type using a query