I realised that the div movement might work in some browsers, and in others not (work in Chrome, but not in Safari for example).

So, you can play with the z-index in the JS function that triggers the video play (playVideoInJWPlayer). Then listen to the close event of the player (it surely has an API as far as I remeber) and restore the z-index to the state it was before play:

document.getElementById("jwPlayer").style.zIndex = "90";



Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Constantin Stan

Constantin Stan

More from Medium

What Are You Studying?

For The Greater Good

Truly Blessed