I'm trying to display a description of a WooCommerce single product, but the instead of displaying the correct description, the loop starts over again displaying the image, price, add to cart etc.
I've tried to find the answer for long time with no avail.
I have used the WooCommerce template scripts and edit them; the_excerpt()
will work but not the_content(
).
This is the template file I am currently using: https://github.com/woocommerce/woocommerce/blob/master/templates/single-product/tabs/description.php
the_content()
is now the problem. Could it be my query or something? I have different way to query my products from index.php, but the archive-product.php is having the same as WooCommerce query has. Could this be the cause, even if it's in the single-product.php the problem?
I use this for the front-page.php:s product loop:
<div class="col-9 main-products">
<?php echo do_shortcode('[products paginate="true" limit="30" orderby="popularity"]'); ?>
</div>
content-single-product.php, archive-product.php and single-product.php are the same as the WooCommerce template has.
It should display the description instead of looping over again. There are no error messages.
I've also used a different theme and the products display correctly, so the problem isn't in any plugins I am using.