All things Shopify and commerce
Good afternoon - I'm hoping someone can help.
I sell ebooks from my website using Shopify Lite. (Example bookstore page)
Recently, several customers have bought the same ebook twice, and I noticed that amazon has an alert that comes up on their site saying "You already purchased this ebook."
Does Shopify have a functionality like this and how do I make it work with Shopify Lite?
Many thanks
J
Solved! Go to the solution
This is an accepted solution.
Thanks a lot - that makes sense, both in terms of why and how. Guess I need to educate my readers to log in, and then set up a way to tag them.
Where are you wanting this alert to show up?
I guess I didn't think about it but the problem is customers aren't always signed in, so you can require sign-in at checkout, but you can't (that I know of) customize the checkout to alert the customer. Maybe on Shopify Plus it's possible. In order to know if a customer has purchased a certain book, they would have to be signed in always.
If you can guarantee your shoppers are signed in, then you can totally use liquid to display a warning on the product page or in the cart. The easiest way would be to have an app tag customers with the product skus they purchase. Then in your theme, you can add code to check if the product sku is present in the customer's tags and then if so, display whatever you want.
If you don't want to do tags, you could do metafields as well. Would still require an app to write the sku to the customer's metafields.
Without tagging or metafields, you could also loop through the customer's orders
{% for order in customer.orders %} {{ order.id }} {% endfor %}
And then for each order loop through the order.line_items and see if the product sku is present.
You could also wrap your cart.liquid in code that checks if the user is logged in, and if not it redirects them to the login page. This would need some testing as I'm not sure their products would stay in the cart after login (I assume they would). But that way the cart can't be accessed unless they're signed in and you can check their tags/metafields/orders.
But this isn't a great experience for customers and could hurt your conversion rates.
This is an accepted solution.
Thanks a lot - that makes sense, both in terms of why and how. Guess I need to educate my readers to log in, and then set up a way to tag them.
Yes, I can see how that's less than ideal. I do a bit of education work first. Thank you!
User | RANK |
---|---|
68 | |
49 | |
36 | |
34 | |
29 |
Learn these 5 things I had to learn the hard way with starting and running my own business
By Kitana Jan 27, 2023Would you love to unleash the unbridled power of the Google Shopping Channel into your sho...
By Gabe Jan 6, 2023How can you turn a hobby into a career? That’s what Emmanuel did while working as a wa...
By Skye Dec 30, 2022