<?php $t_arr = array('00','01','02','03'); $time = date('H',time()); if (in_array($time, $t_arr)) { echo '123123';exit; } echo '4564565';