svn commit: samba-web r238 - trunk
deryck at samba.org
deryck at samba.org
Mon Aug 9 23:43:01 GMT 2004
Author: deryck
Date: 2004-08-09 23:43:01 +0000 (Mon, 09 Aug 2004)
New Revision: 238
WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba-web&path=/&rev=238&nolog=1
Log:
Creates a javascript redirect page to take load off of
samba.org.
--deryck
Added:
trunk/redirect_us.html
Changeset:
Added: trunk/redirect_us.html
===================================================================
--- trunk/redirect_us.html 2004-08-09 20:45:49 UTC (rev 237)
+++ trunk/redirect_us.html 2004-08-09 23:43:01 UTC (rev 238)
@@ -0,0 +1,38 @@
+<html>
+
+<head>
+
+
+<script type="text/javascript">
+
+ randomMirror = new Array;
+ randomMirror[0] = "http://us1.samba.org/";
+ randomMirror[1] = "http://us2.samba.org/";
+ randomMirror[2] = "http://us3.samba.org/";
+ randomMirror[3] = "http://us4.samba.org/";
+
+rnd.today=new Date();
+rnd.seed=rnd.today.getTime();
+
+function rnd() {
+ rnd.seed = (rnd.seed*9301+49297) % 233280;
+ return rnd.seed/(233280.0);
+}
+
+function rand(number) {
+ return Math.ceil(rnd()*number);
+}
+
+index = rand(4)-1;
+
+
+</script>
+
+</head>
+
+
+<body onload="javascript:window.location=randomMirror[index]">
+
+</body>
+</html>
+
\ No newline at end of file
More information about the samba-cvs
mailing list