How to dynamically add wmode="opaque"
to already displaying embed
elements? Without reloading the elements, the embedded content should not lose its state.
Just setting the wmode
attribute with javascript doesn't work.
Removing the element and then adding it again makes wmode
take effect, but the flash element loses its state, among other problems. E.g if it's a video player its position/playback status resets. So that solution is no good.
Any other way of displaying content over the embedded element is acceptable as well.
(I'm doing this trough a content script in a Chrome extension if that is of any help.)
This is not a duplicated of How to dynamically add wmode=transparent to Youtube embed code? as there the parameter is added to a frame and not directly to the element it self.