How to get default time zone in PHP || PHP Codes
×


How to get default time zone in PHP

2580

date_default_timezone_get() function is used to get default timezone in PHP. This is an inbuilt function. It returns the default timezone used by all date/time functions.

Example:

<?php 
 $default_timezone= date_default_timezone_get();
 echo $default_timezone;
?>

Output:

Asia/Kolkata



Best WordPress Hosting


Share:


Discount Coupons

Get a .COM for just $6.98

Secure Domain for a Mini Price



Leave a Reply


Comments
    Waiting for your comments