diff options
Diffstat (limited to 'core/Date.php')
-rw-r--r-- | core/Date.php | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/core/Date.php b/core/Date.php index 909f7adb0e..63c6384729 100644 --- a/core/Date.php +++ b/core/Date.php @@ -627,6 +627,14 @@ class Date return $out; } + public function getHourInUTC() + { + $dateTime = $this->getDatetime(); + $hourInTz = Date::factory($dateTime, 'UTC')->toString('G'); + + return $hourInTz; + } + /** * Adds `$n` days to `$this` date and returns the result in a new Date. * instance. |