Posts: 18
Name: Kiros
Location: Albany, LA - USA
|
Hmmm... Well, I don't have much PHP coding experience yet, but I think that you could use the Date function to return the day and use it inside a switch. The only thing you would need in this case would be 7 cases (if you go by the days) or 28 cases (if you go by the day's number) - 28 because that's the lowest and you could just use the default switch otherwise.
Erm... I think that this would only be a reasonable method if you know the file names you want to include for the different days. If you use the Date function to return the day of the week (Mon, Tue, etc.) then you could make the 7 cases with the default switch. The only maintenance would be either changing each case each week (which would be a little bit of a hassle) or to upload the 7 new files each week and override the old files without changing the names (less of a hassle). Unfortunately, the less of a hassle also has it's downside, as it takes more effort to archive the old files, and if you forget to archive them one week, they're gone (at least on the server).
|