• How do you display the date based on the end-users local computer, not the server?

    Any help is greatly appreciated. Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • I am no expert on the subject, but I suspect that you cannot do that with php since it is executed on the server.

    My guess is that you would need to use javascript.

    Maybe a js expert can offer some help.

    vtxyzzy is correct about the PHP

    If you’re a beginner to javascript, probably the simplest way of output the current time on your site is:

    Simple Javascript Date

    Javascript as was mentioned runs in the browser, on the site visitors side of things. Above is not necessarily the cleanest way to do things but it’s definitely the easiest if you’re new to Javascript. Most JS Experts may bamboozle you with why you shouldn’t use ‘document.write’ etc.

    Good luck with your query, hope this helps.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘PHP Date Function Question’ is closed to new replies.