Your account is limited to posting only in the Pre-Sales Questions forum.
Support forum access is limited to members with a purchase history.

If you are working on behalf of another member, please contact us with the name of the license holder and we will upgrade your account.
   
 
“Verified” buyers
Posted: 27 September 2011 08:37 AM   [ Ignore ]
Wallflower
Rank
Total Posts:  12
Joined  2011-08-23

I am using CartThrob for an e-commerce site. They want reviews for items, but would also like to show ‘verified buyers’ or even limit reviews to actual buyers. Not sure if we will use Channel Ratings be DevDemon or Ratings by Solspace.

I imagine this can be done by a query that checks if the field in the DB that tracks orders can be checked for a value, then show/hide the review form (if limiting who can review) or show a ‘verified’ badge. Correct? If so…any tips on where to start?

Profile
 
 
Posted: 28 September 2011 04:10 AM   [ Ignore ]   [ # 1 ]
Administrator
Avatar
RankRankRankRankRank
Total Posts:  8342
Joined  2008-09-29

Since orders placed are tied to a member id, you can check the database to see if that member ID has been used in an orders entry. If you’re also using the purchased items channel, it’d be real easy to see, as well, if that member is tied to a specific product.


SOMETHING like this. I don’t know that i have the column names right, etc, but something like this is where I’d start:

SELECT from exp_channel_entries WHERE author_id "the logged in member id" AND channel_id "the orders channel id" limit="1" 

If any results are returned, then that person is in the database, and therefore “verified”

 Signature 

NOTE: If I say “I will look into x” and you PM me information, please do not hesitate to contact me again about it, if I do not respond in several hours, or at most a day. Please feel free to remind me as you see fit

Profile