Home > Article > Backend Development > How to tell if time has started
strtotime: Parse English text date and time into Unix timestamp
<?php if(time()<strtotime(Configure::read("Shuang_START"))):?> alert('活动尚未开始~');return; <?php endif;?> <?php if(time()>strtotime(Configure::read("Shuang_END"))):?> alert('活动已经结束~');return; <?php endif;?>
The above is the detailed content of How to tell if time has started. For more information, please follow other related articles on the PHP Chinese website!