mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 17:16:18 +00:00
Removing php5 only code.
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7402 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
4a94397b43
commit
c5cfc77365
1 changed files with 1 additions and 4 deletions
|
@ -54,10 +54,7 @@ class TimeHelper extends AppHelper {
|
|||
* @return int Offset
|
||||
*/
|
||||
function serverOffset() {
|
||||
$timezoneServer = new DateTimeZone(date_default_timezone_get());
|
||||
$timeServer = new DateTime('now', $timezoneServer);
|
||||
$offset = $timezoneServer->getOffset($timeServer);
|
||||
return $offset;
|
||||
return date('Z', time());
|
||||
}
|
||||
/**
|
||||
* Returns a UNIX timestamp, given either a UNIX timestamp or a valid strtotime() date string.
|
||||
|
|
Loading…
Add table
Reference in a new issue