Jump to content

Change Server Time And Date


japapa

Recommended Posts

The time on both - Stevie and Johnny - are correct (except small issue with time in HTTP headers sent from Stevie being 24 seconds behind for some reason, while time served inside PHP scripts with date and time functions is correct).

 

Default timezone set on both servers is "America/Los_Angeles" - which is PST in winter and PDT in summer.

 

If you want to use different timezone you have to specify your own value either inside of your PHP scripts (in every one of them) with:

putenv("TZ=xyz");

or with:

date_default_timezone_set("xyz");

 

OR for all your scripts with using the following entry in .htaccess file:

SetEnv TZ xyz

 

where xyz will be selected timezone identifier. All timezones you can find in here:

http://php.net/manual/en/timezones.php

 

If I'm right then most probably best for you will be using "Asia/Tehran" timezone, as this is the place where GMT+03:30 (IRST) is used in winter, and GMT+04:30 (IRDT) in summer.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...