Tips and Tricks HQ Support

Support site for Tips and Tricks HQ premium products

  • Home
  • Contact Us
  • Documentation
  • Forum Home
    • Forum
    • Forum Search
    • Forum Login
    • Forum Registration

Reply To: eStore – Using a custom post type with metadata and Add to Cart

by

Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › WP eStore Tweaks › eStore – Using a custom post type with metadata and Add to Cart › Reply To: eStore – Using a custom post type with metadata and Add to Cart

June 13, 2013 at 11:45 pm #56094
admin
Keymaster

Hi, Adding a purchase button for your product in the template file won’t be hard. Here is an example snippet of code that can retrieve the product ID value of a post from the custom field and then creates an “add to cart” button for that product:

<?php
$product_id = get_post_meta($post->ID, 'product_id', true);
get_button_code_for_product($product_id);
?>

Do you have a system in place for doing all these custom post type stuff though?

Forum Related

  • Forum Home
  • Forum Search
  • Forum Registration
  • Forum Login

Support Related Forms

  • Contact Us
  • Customer Support
  • Request a Plugin Update
  • Request Fresh Download Links

Useful Links

  • Plugin Upgrade Instructions
  • WP eStore Documentation
  • WP eMember Documentation
  • WP Affiliate Platform Documentation
  • Tips and Tricks HQ Home Page
  • Our Projects

Quick Setup Video Tutorials

  • WP eStore Video Tutorial
  • WP eMember Video Tutorial
  • WP Affiliate Platform Video Tutorial
  • Lightbox Ultimate Video Tutorial

Our Other Plugins

  • WP Express Checkout
  • Stripe Payments Plugin
  • Simple Shopping Cart Plugin
  • Simple Download Monitor

Copyright © 2026 | Tips and Tricks HQ