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

eStore – Want PHP code to know if user did buy 1 particular product?

by

Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › WP eStore Tweaks › eStore – Want PHP code to know if user did buy 1 particular product?

  • This topic has 4 replies, 2 voices, and was last updated 10 years, 1 month ago by Ghislain D.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • March 24, 2015 at 9:58 pm #12396
    Ghislain D
    Spectator

    I have Emember 8.8.5 and e-store. I need to do something easy for you.

    On My Website Free content is available to Visitors (so No free membership)

    I have one Membership ONLY and No subscription

    As a member you can buy products. I have 5 products.

    Member can buy any of the 5 products, or 2 or 3 or all of them.

    I want to know (for a logued in member) :

    In a WP custom page I want to show information according their purchase.

    So If products are A,B,C,D,E ( or using productID from e-strore)

    In PHP how do I know if their purchased one particular product?

    I need php because I do calculation after

    If a shortcode exist I can try to work with it

    thank you

    March 25, 2015 at 3:13 am #69281
    admin
    Keymaster

    If you allow anonymous checkout (meaning you don’t know which member is buying what) then you can’t magically figure out who bought what afterwards.

    It seems like you want to use a purchase history system:

    https://www.tipsandtricks-hq.com/wordpress-membership/how-to-display-a-members-purchase-history-158

    You will need to make sure the members are logged into the site when they purchasing the item. Only then the plugin can track which member is buying what.

    March 25, 2015 at 1:52 pm #69282
    Ghislain D
    Spectator

    Well may be I was not clear enough.

    Only members can buy products.

    I need to make calculation based on specific product they purchased.

    They are all registered and loggued.

    Is there in the database something that links eMemberID to ProductID ?

    Does not have to be a shortcode. PhP is fine

    March 25, 2015 at 11:03 pm #69283
    admin
    Keymaster

    Yes. Check the “eStore_show_members_purchase_history” function from the “eStore_misc_functions.php” file to see how it can find all the products purchased by a member.

    March 26, 2015 at 6:33 pm #69284
    Ghislain D
    Spectator

    Ok thanks I will do that

  • Author
    Posts
Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.
Log In

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 © 2025 | Tips and Tricks HQ