37,721
社区成员
发帖
与我相关
我的任务
分享
function getTeststarttime($value) {
$value1 = explode(" ", $value);
if (is_array($value1)) {
if (trimall(trim($value1['2']) == "PM")) {
$timePlus = 12 * 60 * 60;
} else {
$timePlus = 0;
}
$temp = $value1['0'] . " " . $value1['1'];
if (strtotime($temp) > 1262275200) {
$dateInt = strtotime($value1['0']);
$timeInt = $this->timeToint($value1['1']);
if ($timeInt >= 12 * 60 * 60 and $timePlus == 0) {
$timeInt = $timeInt - 12 * 60 * 60;
}
$timeInt >= 12 * 60 * 60 ? $timePlus = 0 : $timePlus = $timePlus;
$returnValue = $dateInt + $timeInt + $timePlus;
} else {
$returnValue = 0;
}
} else {
$returnValue = 0;
}
return $returnValue;
}