@pete96
There are many ways to do it, but it will require some coding knowledge.
1. All products URL have a JSON endpoint with all complete data. For instance, take this product:
https://partakefoods.com/products/crunchy-cookie-variety-pack
And add .json at the end, and you'll receive all of its data:
https://partakefoods.com/products/crunchy-cookie-variety-pack.json
From there you just need to create a Javascript function to get the current variant.
2. Perhaps the simpler one, in your product-template file ensure that the product has only one variant and create a data attribute with something like "data-custom-variant-id" passing the variant ID. From there you'll just need to add it via Javascript.
If you're unfamiliar with coding feel free to reach out just by clicking here, I'll be happy to help.
Kind regards,
Diego
Hi Diego,
You are a genius!!!
Many thanks for idea #1 and for pointing this out. I am sure we can do something with this, and it won't require us to make any changes to the site at all, everything we need will be in the data returned by the json call.
I know where to come for any development we might need! (and it might be soon!)
Hope all is well down there in sunny Portugal,
Many thanks for taking the trouble to reply and for giving me this info
pete
User | Count |
---|---|
25 | |
21 | |
20 | |
16 | |
15 |