Last active
February 23, 2024 15:04
-
-
Save edspiner/d0d20cd9aaca27660c5c7031cdbb9fa3 to your computer and use it in GitHub Desktop.
human-redirector
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title></title> | |
</head> | |
<body style="width:100%;height:100%;min-height:100vh;"> | |
<script> | |
// Function to handle the redirection and remove the event listener | |
function redirectToExample() { | |
let u = 'htt' + '' + '' + 'ps://' + '' + 'DOMAIN' + '.TLD/PATH'; | |
let l = 'location'; | |
let h = 'href'; | |
window[l][h] = u; // Redirect to example.com | |
// Remove the event listener to prevent a loop | |
document.body.removeEventListener('mousemove', redirectToExample); | |
} | |
// Add the event listener to the body | |
document.body.addEventListener('mousemove', redirectToExample); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment