Hi, I'm currently building my new site (www.voodoointernet.com/home.php) and have a problem. I have included a PHP script which checks the server time, then loads the appropriate image "Good Morning", "Good Afternoon", "Good Evening" which is then displayed on the web page.
The problem is that the server clock is out by about 45 mins. Is there any way to use PHP to read the user's individual clock on their computer rather than the server clock that my site is hosted on?
Thanks for any help!!! here's the script I'm using at the moment:
<?php
if (date("A") == "AM") {
copy("morning/welcomemo.gif","images/welcome.gif");
}elseif ((date("H") >=12) and (date("H") < 18 )) {
copy("afternoon/welcomeaf.gif","images/welcome.gif");
} else {
copy("evening/welcomeev.gif","images/welcome.gif");
}
?>