Reputation: 473
I have developed my website in wordpress and it's error_log
uses the default server time zone, but i want it to use my timezone which is Asia/Kuwait
.
How to adjust/change the server to use my region's time zone.I'm using Wordpress and i have no access to the php.ini
Upvotes: 0
Views: 848
Reputation: 135
use below code to set your default time zone set.
paste this code in index.php file
<?php date_default_timezone_set('Asia/Kolkata'); ?>
set your timezone using wp-admin dashboard. General Settings->Timezone
Upvotes: 0
Reputation: 1
Use this reference :
http://php.net/manual/en/timezones.php
Good luck.
Upvotes: 0
Reputation: 574
You can change it in your php.ini file by changing the value of date.timezone
date.timezone = Asia/Kuwait
This link explains how to do so.
Upvotes: 0
Reputation: 2474
I think you are looking for: date_default_timezone_set ( string $timezone_identifier )
You can also set this in your php.ini config.
[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = Europe/Berlin
Upvotes: 3