Hi,
My problem is that I have two tables that change...
$query1 = "INSERT INTO tableA(name, type, size, content, file_date, section) SELECT name, type, size, content, file_date, section FROM table2 WHERE CURDATE() >= DATE_ADD(file_date, INTERVAL 1 DAY)";
$result1 = mysql_query($query1) or die(mysql_error());
Basically tableA and table2 should change based on what data is inserted.
So if checkbox A is selected fileA will be inserted from table2 into tableA
If checkbox B is selected fileB will be inserted from table3 into tableB.
I created an array of one set of tables(those affected by INSERT) and did this...
$tables = array('mergers', 'rights', 'spin_offs', 'splits');
foreach ($tables as $table)
{...
But how do I do it when both tables should change?
Make sense?
thanks.