i will never forget that time when i discovered that if you have two bandcamp tabs, one of which is playing, and you start playing in the other, the first one will pause, and it was all being done with a very complicated message bus based on polling cookies at high frequencies

i'm sure it doesn't work like that anymore but, fuck

it was so janky and so cool

Follow

doesn't work if some pages are on a custom domain... but i'm fairly sure they could make it work with a hidden iframe

now i am reminded of how shit the document.cookie "api" is

thankfully there are no good reasons to use it these days

@codl if only there were some method of sending messages between web browser tabs

@ben there wasn't at the time i first found this (which is why it was impressive)

also it is still not exactly straightforward

@codl browsers hate cookies in iframes. that way only leads to pain.

@codl So they key is to call window.parent.postMessage, which allows you to send the message from the iframe to the document load embeds the iframe?

I'm still trying to get my head around why this isn't a security problem.

Sign in to participate in the conversation
Chitter

Chitter is a social network fostering a friendly, inclusive, and incredibly soft community.