I am developing a page to view a preview of the documents available to the user.
For preview I use iframe with src = https://docs.google.com/viewer?authuser=0&srcid= {document id}
The problem is that when the user does not register, he shows an empty iframe.
I want to redirect the user to the google login page if the current user is not logged in and then displays the page while viewing the document.
For this feature, I will first need to check if the user is registered with Google or not.
I think google has some limitations imposed in the case of an iframe so that it does not redirect to the login page.
How can I implement it through the API?
source
share