Skip to content

Instantly share code, notes, and snippets.

@mattm
Created January 25, 2018 16:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mattm/7d9121eb1d3677daa68b269dd23ca379 to your computer and use it in GitHub Desktop.
Save mattm/7d9121eb1d3677daa68b269dd23ca379 to your computer and use it in GitHub Desktop.
A bookmarklet to prompt you for a new document.referrer
javascript:(function(){
var newReferrer = prompt('Set the referrer:');
Object.defineProperty(document, "referrer", {configurable: true, get : function(){ return newReferrer; }})
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment