prepare($query); $data = strtotime($_POST["lesson_date"]); $time = strtotime($_POST["lesson_time"]) - strtotime("today"); $datatime = ($data+$time)*1000; $duration = strtotime($_POST["duration"]) - strtotime("today"); $sth->execute(array($_POST["title"] , $_POST["subtitle"] ,$datatime, $duration , $_POST["live"] , $_POST["replay"] , $_POST["summary"] , $_POST["teacher"] , mTime() , mTime() , $_POST["lesson"])); $respond=array("status"=>0,"message"=>""); if (!$sth || ($sth && $sth->errorCode() != 0)) { $error = PDO_ErrorInfo(); $respond['status']=1; $respond['message']=$error[2]; echo "
Lesson 数据修改失败:{$error[2]}
"; } else{ $respond['status']=0; $respond['message']="成功"; echo "
Lesson 数据修改成功
"; echo $d=strtotime("today"); echo strtotime($_POST["lesson_date"])."
"; echo strtotime($_POST["lesson_time"])."
"; echo (strtotime($_POST["duration"]) - $d)."
"; } //echo json_encode($respond, JSON_UNESCAPED_UNICODE); ?>