rsvore
03-09-2005, 08:18 PM
I'm creating a simple script to redirect a page to a different html page by checking the day of the month. The script looks into the directory with the html pages listed 1 - 31 (i.e. 1.html, 2.html etc). What I want to do is make the javascript seach a particullar directory (menu) to find the html pages. Can any help?
I have the following directory:
-Website
--menu
---1.html
---2.html
Here is the script:
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var today = new Date();
var day = today.getDate();
window.location = day + ".html";
// End -->
</SCRIPT>
In this line
window.location = day + ".html";
can I change it to
window.location = day + "/menu/.html";
Thanks,
Rob
I have the following directory:
-Website
--menu
---1.html
---2.html
Here is the script:
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
var today = new Date();
var day = today.getDate();
window.location = day + ".html";
// End -->
</SCRIPT>
In this line
window.location = day + ".html";
can I change it to
window.location = day + "/menu/.html";
Thanks,
Rob