|
|
Java menu script>Menu Make>Day of Week Redirection
|
| If you would like to redirect your visitor to a different page
for each day of the week, this script would be perfect. It will first detect what day of
the week it is and then forward the visitor to the appropriate page. I also might mention
that this is a perfect JavaScript example to learn from even if you don't use it. Just
look at it! |
|
<!-- ONE STEP TO INSTALL DAY OF WEEK REDIRECTION:
1. Paste the coding into the HEAD of your HTML document -->
<!-- STEP ONE: Copy this code into the HEAD of your HTML document -->
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->
<!-- Begin
function initArray() {
this.length = initArray.arguments.length;
for (var i = 0; i < this.length; i++)
this[i+1] = initArray.arguments[i];
}
var DOWArray = new
initArray("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");
var today = new Date();
var day = DOWArray[today.getDay()+1];
window.location = day + ".html";
// End -->
</SCRIPT>
<p><center>
<font face="arial, helvetica" size="-2">Free JavaScripts
provided<br>
by <a href="http://javascriptsource.com">The JavaScript
Source</a></font>
</center><p>
<!-- Script Size: 0.79 KB -->
|
|
|
|