WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce - excelling eCommerce
[resolved] Old Template Single Product Page [FIXED!] (1 post)

  1. DevDm
    Member
    Posted 1 year ago #

    Just wanted to help out anyone else who is using Woocommerce with an old not supported template. The instructions from The Woo folks blinded me to a painfully obvious solution to my problem.

    I followed the instructions by duplicating page.php to woocommerce.php and replacing "the loop" with:

    <?php woocommerce_content(); ?>

    But was still not having my "Individual Product" pages being processed though the woocommerce loop at all. They were being treated like regular posts.

    The light bulb FINALLY went off that my old template had a "single.php" file and that woocommerce products were a custom post type of "product."

    So I duplicated my single.php to single-product.php (for the custom post type)and replace "the loop" with:

    <?php woocommerce_content(); ?>

    PRESTO! My individual products were now working!

    So in the end if you have an old template you might need to make TWO files and not just the one:

    page.php -> woocommerce.php
    single.php -> single-product.php

    If anything I hope this gets into the ether. I google'd forever and couldn't find squat about my problem. Woocommerce is pretty awesome once you get the hang of it.

    I might blog about a few other things I found later. DevDm Blog

    http://wordpress.org/extend/plugins/woocommerce/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic