The example of this article describes the method of getting today's start time and end time in PHP. It has a very good reference value. Let's take a look at it with the editor.
Without further ado, please look at the code :
$begintime=date("Y-m-d H:i:s",mktime(0,0,0,date('m'),date('d'),date('Y'))); $endtime=date("Y-m-d H:i:s",mktime(0,0,0,date('m'),date('d')+1,date('Y'))-1);
For more articles related to PHP getting today’s start time and end time, please pay attention to the PHP Chinese website!