How to get local time in php?

前端 未结 7 1266
野性不改
野性不改 2021-02-02 03:12

I am trying to get the local time using php. I wrote two different versions, but they both give the wrong time

date_default_timezone_set(\'UTC\');
$now = new Dat         


        
7条回答
  •  深忆病人
    2021-02-02 03:49

    If you don't want to use timezone you can use this mix of windows and php commands:

    
    

提交回复
热议问题