Home > Backend Development > PHP Tutorial > php怎么表示从当前日期起三个月之内的数据

php怎么表示从当前日期起三个月之内的数据

WBOY
Release: 2016-06-13 11:09:15
Original
1499 people have browsed it

php如何表示从当前日期起三个月之内的数据
php如何表示从当前日期起三个月之内的数据
查询语句用那个函数?
------解决方案--------------------

echo $deltime=strtotime("-90 days");

echo "


";
$sql="delete from yourtable where dateandtimeecho $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();
?>
Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template