Closed alpeshgaglani closed 9 years ago
On browsers that allow 3rd party cookies (Safari doesn't) you could simply make an XHR call to slave.com/logout
and have the slave server Set-Cookie
:`(blank). If you want it to work across all browsers, you'll have to **redirect** to
slave.com/logout` (this way you're not in an iframe and you're not affected by same-origin policy).
I am wondering what's the best way to define custom events. For example, I have the "slave" domain that has auth cookies for communicating with my API tier. I want to trigger a logout event from my "master" domain that will tell the "slave" domain to clear out the cookies. Is it a good idea to do so? What would be the best way to go about it?