php如何表示从当前日期起三个月之内的数据
php如何表示从当前日期起三个月之内的数据
查询语句用那个函数?
------解决方案--------------------
echo $deltime=strtotime("-90 days");
echo "
";
$sql="delete from yourtable where dateandtime
echo $sql;echo "
";
$con = mysql_connect("localhost","root","yourpassowrd");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("yourdb", $con);
mysql_query($sql,$con);
mysql_close($con);
echo "
Are You OK?
";
echo time();
?>
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn