Hey, I want to load a different bit of content depending on the day of the week.
PHP - Content depending on day of week
10
Hey,
I want to load a different bit of content depending on the day of the week.
It's working.. I think..
I have this in the <head>..
.. and then, of course, I have..
.. where I want the daily content to be ..
and then in the same directory I have..
t0.php (Sunday)
t1.php (Monday)
t2.php (Tuesday)
t3.php (Wednesday)
t4.php (Thursday)
t5.php (Friday)
t6.php (Saturday)
What I'm wondering is.. will the content depend on my server or will it depend on the users timezone...
Obviously I want it based on my users timezone..
Could someone please advise..
I want to load a different bit of content depending on the day of the week.
It's working.. I think..
I have this in the <head>..
Code:
<?php
$day=date("w");
$file="t".$day.".php";
// anywhere on your page, you include the file.
//include($file);
?> .. where I want the daily content to be ..
and then in the same directory I have..
t0.php (Sunday)
t1.php (Monday)
t2.php (Tuesday)
t3.php (Wednesday)
t4.php (Thursday)
t5.php (Friday)
t6.php (Saturday)
What I'm wondering is.. will the content depend on my server or will it depend on the users timezone...
Obviously I want it based on my users timezone..
Could someone please advise..
- RenardNET
- Joe Motion
- RenardNET
- Joe Motion
- [1] reply
- Brandon Tanner
- [ 3 ] Thanks
- [3] replies
Next Topics on Trending Feed
-
10