PHP将时间转换为整形函数strtotime()
示例:
示例:
<?php
$str=strtotime("2012-03-09 10:49:56");
echo date("Y-m-d H:i:s",$str)
//$str=1331290196
//输出结果:2012-03-09 10:49:56
?>