Home » Php » timezone – How can I detect day light savings automatically in PHP?

timezone – How can I detect day light savings automatically in PHP?

Posted by: admin April 23, 2020 Leave a comment

Questions:

How can I detect day light savings automatically in PHP?

How to&Answers:
echo date('I');

The I (capital i) is a 1/0 denoting whether or not daylight saving is currently in effect.

http://php.net/manual/en/function.date.php

hope it helps.