Not that I wanna do it anytime soon but I do wanna know how it's done. When a website has music, it usually stops playing after you navigate to another page on the site, and then it starts playing again when that page loads.
How would I keep the music playing even if the user clicks on a link? I don't wanna put my website on a frame.
And also, if they open a new tab of the website how would I stop the song from replaying on that tab if they're already playing it?
Method 1:
Method 2:
Method 3:
Method 4:
As far as active browser tab say you were using jQuery you can check that using window.focus & window.blur events: