Hey Peoples,
I have a bit of a query for you PHP peoples out there.
I have a table which has a field called "regdate" ( Registration Date ), This is put in by the php as follows
date("d/m/y")
So an example of an entered date would be: 14/02/07
I want to run a php script via cron everyday, that deletes records that are 3 months or more old.
I have the code to connect to the database / table as follows, but that is as far as i got.
<?php
$location = "localhost";
$username = "username";
$password = "password";
$database = "database";
$conn = mysql_connect("$location","$username","$password");
if (!$conn) die ("Could not connect to database server");
mysql_select_db($database,$conn) or die ("Could not open database");
?>
Any help on this problem would be greatly appreciated.
Cheers