PHP date_default_timezone_get() Function
Definition
The date_default_timezone_get() function returns the default timezone used by date/time functions.
Syntax
PHP date_default_timezone_get() Function has the following syntax.
date_default_timezone_get();
Return
PHP date_default_timezone_get() Function returns the timezone as a string.
Example
Return the default timezone:
<?php
echo date_default_timezone_get();
?>
The code above generates the following result.