Search code examples
phpreferrer

Is it possible to remove the referrer in PHP before redirected?


But since the browser is the only thing that manages the referrer, however I was thinking about a script that removes the referrer before they are redirected to the link they want to go to.

For example,

http://mywebsite.com/url.php?u=http://www.stackoverflow.com

Where url.php could remove the referrer and then redirect. Is it possible to do this in any way?


Solution

  • If your redirect is an HTTP redirect then, no, you have no control over that.

    Nor, frankly, should you. It's the browser's business to form the REFERER value, not yours.