www.webdeveloper.com
Results 1 to 3 of 3

Thread: displaying time in a web page

  1. #1
    Join Date
    Jun 2013
    Posts
    20

    displaying time in a web page

    hi.

    i'm working on my first web page and what i want to do is to display the time of the user who visits the page, and the server time (i need it because some actions happenede periodically depending on servers time like "everyday at midnight...etc)

    so what i need is to display something like this

    TIME: HH:MM:SS
    SERVER TIME: HH:MM:SS

    the time has to change dinamycally every second obviously.

    how can i do that?
    THX

  2. #2
    Join Date
    Mar 2012
    Posts
    1,278
    Displaying the time is best done client-side in JavaScript. However, that will not give you the server time. Why on Earth do you need to display the server time anyway???

  3. #3
    Join Date
    May 2005
    Location
    Gold Coast (MS)
    Posts
    2,208
    Maybe:

    Cut & Paste Live Server Time script (SSI or PHP) - http://www.javascriptkit.com/script/...rvertime.shtml

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles