Skip to content

Instantly share code, notes, and snippets.

@djsnipa1
Last active December 19, 2022 20:07
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 djsnipa1/58aeb085ddcb514209d47fa353156fa7 to your computer and use it in GitHub Desktop.
Save djsnipa1/58aeb085ddcb514209d47fa353156fa7 to your computer and use it in GitHub Desktop.
Test hyperweb script
//==UserScript==
// @name Redirect Google
// @description Redirect Google to Yahoo!
// @include http://*.reddit.com/*
// @run-at document-start
//==/UserScript==
window.location.replace(/www.reddit.com/, /reddit.chadf.ml/)
/*
const load = () => {
if (window.location.href.match('www.reddit.com')) {
location.href = location.href.replace(/www.reddit.com/, /reddit.chadf.ml/)
console.log(location.href);
}}
*/
// window.onload = load;
// if (window.location.href.match(reddit.com)){
// window.location.href = window.location.href.replace(/reddit.com/, /reddit.chadf.ml/)
// }
//
// window.onload = libreddit()
//
// function libreddit(){
// window.location.href = window.location.href.replace(/reddit.com/, /reddit.chadf.ml/)
//
// }
@makerio90
Copy link

why not libredirect?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment