Wednesday, September 17, 2014

Changing default timezone in WAMP

I use WampServer on Windows 7. I tried to display the default time using PHP, but the wrong time was displayed.

Well, the default timezone was incorrect. How to change it?
First, click the WAMP icon, then go to PHP, then open php.ini.

Now, search for "date.timezone", then change the value from UTC to anything you want.
In my case, I changed it to Australia/Sydney.

You can find the list of supported timezones here: