Jump to content
The Uniform Server Community

Server time?


Recommended Posts



First my thank you to the volunteer/developer of this package.


I have a question in changing my server time I've tried using



"date.timezone = "Canada/Mountain"" and "America/Edmonton


in my php.ini/php development and php cli. still my server timezone wont change to the above time.


any reason i could be doing this wrong?





msevero :)


UniServer 5.6b

windows xp

Link to comment
Share on other sites

First thanks for stating the US version.


The line:

date.timezone = "Canada/Mountain"

As you rightly pointed out should be placed in each of these files






Background php.ini is the file PHP uses at start-up. Switching between production and development switches in the corresponding file that overwrites php.ini (Note you need to restart the server for any changes to be picked up) The control uses php-cli.ini no real need to change this file.


I added the above line to php.ini and it works correctly.

Now assuming you have not made a typo it is possible that a third party application is overriding the setting!


A quick test is to edit file UniServer\www\.htaccess

At the end of this file add the following line:

php_value  date.timezone "Canada/Mountain"

Create a new file UniServer\www\time.php

Add this code:

echo date("l, F d, Y h:i" ,time());

Run the file as follows type into your browser:



(Note: No need to restart servers)

That should display the correct time for your time zone.

If it does either the problem is a typo or a third party application.


All the best

Ric :)

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.

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...