New Zenner
- Join Date:
- Aug 2013
- Posts:
- 56
- Plugin Contributions:
- 0
Display how many times a product has been purchased?
How to show customer also purchased product in shopping cart page?
Thanks!
Views: 4,939
New Zenner
How to show customer also purchased product in shopping cart page?
Thanks!
Zen Follower
Hi Ajeh,
I put following code on product_info but it did not work. What I am missing here. Do I need to add something else to same or other file?
(int)$_GET['products_id']
'Sold: ' . zen_products_lookup((int)$_GET['products_id'], 'products_ordered');
Oba-san
I am not quite sure what you are doing there ...
Using:
echo 'Sold: ' . zen_products_lookup((int)$_GET['products_id'], 'products_ordered');
should display how many have been ordered ...
Linda McGrath
If you have to think ... you haven't been zenned ...
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
Zen Follower
I got it. Thank you!
Zen Follower
Ajeh,
Is it possible to not display it when sold is 0 or less than certain number e.g. 5 or 10?
Oba-san
You could add an IF around it to control when it should or should not display ...
Linda McGrath
If you have to think ... you haven't been zenned ...
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
Zen Follower
I already tried that but it did not work. Can you please help me with this to not display when its 0.
Oba-san
You could use something like:
echo (zen_products_lookup((int)$_GET['products_id'], 'products_ordered') < 1 ? '' : 'Sold: ' . zen_products_lookup((int)$_GET['products_id'], 'products_ordered'));
Linda McGrath
If you have to think ... you haven't been zenned ...
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
Zen Follower
Thanks. worked :)
Oba-san
Thanks for the update that this is working for you ... :smile:
Linda McGrath
If you have to think ... you haven't been zenned ...
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
Tell staff why this post should be reviewed.