What is default timezone in php? I checked it in the php.ini which shows the following with the timezone is left blank:
[Date]
; Defines the default timezone
A simple code you have to write for the default timezone. which is:
date_default_timezone_get()
Now how to use:
You have to pass the timezone in this function like we want to set India timezone as default see:
date_default_timezone_set("Asia/Kolkata");
Now, whenever you would use date(), automatically return India timezone.
I would refer if you want a example: how to convert default date timezone in php