WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce - excelling eCommerce
[resolved] Place "Add to Cart" link next to custom post type. (3 posts)

  1. theatereleven
    Member
    Posted 11 months ago #

    I've installed WooCommerce (it rocks) and I've got a simple need, but just not sure how to do it:

    My custom WP site already has product pages that are laid out in a detailed manner - I'm not re-working them for WooCommerce. All I need to do is place an "Add to Cart" button on my existing pages that references the right product in WooCommerce and adds it to the cart.

    Is this possible? My custom pages are using either ACF or custom post types (depending on the page).

    Thanks!!!

    BTW - I've tried using their short codes, but I can't get them to show anything. I'm using the format: <?php echo do_shortcode("[product id="99"]"); ?>.

    It just breaks the page.

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

  2. Roy Ho
    Member
    Posted 11 months ago #

    You can use the WC shortcodes to add a "add to cart" button in any page you want.

  3. theatereleven
    Member
    Posted 11 months ago #

    You know...found the answer.

    This formatting worked:

    <?php echo do_shortcode('[product id="99"]'); ?>

Reply

You must log in to post.

About this Plugin

About this Topic