I'm having trouble with a conditional logic I'm trying to put on my checkout page.
I am able to call checkout API with appropriate cart data. From here, customer can pay for order. After completion of order I want to redirect customer to my own web-site (not my-site.shopify.com) from where I redirect customer to shopify.
I can achieve this with some script on script-tags API. But I want to execute that script-tag only and only if customer placed order from my own web-site. I mean If a customer goes to my-site.shopfy.com from my site, then I want to redirect customer on my own web-site.
I found solutions if customer want to purchase one particular variant of one product. But I want only if customer comes from my own site (referrer).
That will be a conditional script. If i don't put any condition, they regular shopify customer (not coming from my own web-site) will be also redirected to my own web site which I don't want to do. Will need some token in response as well.
If anyone has any tips or pointers on this, that would be awesome.
Thanks so much!
|an hour ago|
|2 hours ago|