So, my server is being hosted in a different timezone ( 2 hours difference ) and I use the date() function to insert the time into a database for a blog, but it shows the servers current time, and that tends to be quite irritating... Is there any way to insert MY current time into the database instead of the servers?
Date() function showing the wrong time.
Re: Date() function showing the wrong time.
You can set the timezone with date_default_timezone_set(), for a list see http://www.php.net/manual/en/timezones.php
Re: Date() function showing the wrong time.
alright, thank youjacek wrote:You can set the timezone with date_default_timezone_set(), for a list see http://www.php.net/manual/en/timezones.php