Created
December 26, 2017 23:43
-
-
Save OkoyaUsman/47db269bf425babbd43c9600c89a0197 to your computer and use it in GitHub Desktop.
A simple random page redirector using Javascript. Note: Please don't forget to add comma , after each of the link (except the last link) and please put http:// or https:// in-front of each link.
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
var linkList = [ | |
"https://google.com", | |
"https://yahoo.com", | |
"https://facebook.com", | |
"https://twitter.com", | |
"https://ebay.com", | |
"https://youtube.com" | |
]; | |
var randomLink = linkList[Math.floor(Math.random()*linkList.length)]; | |
window.location.href = randomLink; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment