I'm trying to add Google Drive file picker to my web app.
My app uses many subdomains (one for each customer account), and some CNAME domain mapping as well.
Since 'Google Developers Console' limits me to specific 'JavaScript Origins' (no wildcard allowed), I fail while trying to authenticate from a subdomain or mapped-domain.
Tried the following workaround: run the picker from an iframe with an absolute URL. No success with this error:
Incorrect origin value. Please set it to - (window.location.protocol + '//' + window.location.host) of the top-most page
Any ideas or workaround to suggest? Thanks in advance :)
You could use a window.open()
popup that sits a the same domain every time, then use window.postMessage()
to communicate between that page and the page at the subdomain.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With