RE: [PHP] How to update a clock every second?
| From: | Cristian Draghici | Date: | Sun, 10 Sep 2000 12:40:55 +0000 |
| Subject: | RE: [PHP] How to update a clock every second? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-16050@lists.php.net to get a copy of this message | ||
yes it will work.
imagine this:
<script language=javascript>
<!--hide from old browsers
function get_time(timeonserver)
{
<?php
echo "var timeonserver=$timefromphp;\n";
?>
return timeonserver;
}
end of script-->
</script>
>-----Original Message-----
>From: Rick Yin [mailto:from929@yahoo.com]
>Sent: Sunday, September 10, 2000 7:32 AM
>To: Matt McClanahan
>Cc: PHP List
>Subject: Re: [PHP] How to update a clock every second?
>
>
>Actually I write one with Javascript. It takes the
>time from a user's system. But the user's system may
>have wrong time set.
>
>So now I'm thinking maybe I can use php to get the
>server time and then pass it over to javascript. Kind
>of a newbie here, if you don't think this would work,
>drop me a line.