Hide referrer on iframe Firefox

206 Views Asked by At

I have a iframe where videos played when the user choose. Everything is on my website, but I want to hide the referrer to the user, so they don't know in what page the videos are. I'm trying with referrerpolicy="no-referrer", but in firefox doesn't work, in chrome works fine. Anyone know why this happens and how to fix it?

<iframe class="embed-responsive video" id="myvideo" src="" referrerpolicy="no-referrer" 
scrolling="no"></iframe>
1

There are 1 best solutions below

4
Buffoonism On

It looks like what you are trying to do is valid, but there are several open bugs in firefox that prevent this from working as it should.

You may be able to fix this at the server level though, through the use of the referrer-policy header. Tweak your server config so that the videos are returned with this header set:

Referrer-Policy: no-referrer