Here's an example, modifying some of Chroder's code from another post:
Code:
<html>
<head>
<script>
var url1 = "http://www.google.com";
var url2 = "http://www.microsoft.com";
var url3 = "http://www.webmaster-talk.com";
var urlArray = [url1, url2, url3];
var rand = Math.round(Math.random() * (urlArray.length - 1) );
var redirectURL = urlArray[rand];
window.location = redirectURL;
</script>
</head>
<body>
<p>
Here's some text that shouldn't ever be seen, except of course by people who don't have JavaScript-enabled browsers.
</p>
</body>
</html>
|