djbaxter
02-24-2007, 02:08 PM
First, my apologies in advance if I'm posting this in the wrong place.
I'd like to adapt Amy's Mass Delete Old Private Messages (https://vborg.vbsupport.ru/showthread.php?t=27421) script for vB 2.x to work with version 3.60.
The existing version shows:
<?php
require ("global.php");
$time = time() - (60 * 24 * 60 * 60);
$a = $DB_site->query("DELETE FROM privatemessage WHERE dateline < $time");
?>
In 3.64, I see three variables for private messages:
pm
pmreceipt
pmtext
Can I just duplicate the a$ query above to prune each of those variables? That is:
<?php
require ("global.php");
$time = time() - (60 * 24 * 60 * 60);
$a = $DB_site->query("DELETE FROM pm WHERE dateline < $time");
$a = $DB_site->query("DELETE FROM pmreceipt WHERE dateline < $time");
$a = $DB_site->query("DELETE FROM pmtext WHERE dateline < $time");
?>
I'd like to adapt Amy's Mass Delete Old Private Messages (https://vborg.vbsupport.ru/showthread.php?t=27421) script for vB 2.x to work with version 3.60.
The existing version shows:
<?php
require ("global.php");
$time = time() - (60 * 24 * 60 * 60);
$a = $DB_site->query("DELETE FROM privatemessage WHERE dateline < $time");
?>
In 3.64, I see three variables for private messages:
pm
pmreceipt
pmtext
Can I just duplicate the a$ query above to prune each of those variables? That is:
<?php
require ("global.php");
$time = time() - (60 * 24 * 60 * 60);
$a = $DB_site->query("DELETE FROM pm WHERE dateline < $time");
$a = $DB_site->query("DELETE FROM pmreceipt WHERE dateline < $time");
$a = $DB_site->query("DELETE FROM pmtext WHERE dateline < $time");
?>