#### Delete members who've not posted for # days UPDATE!!!,
#### by C.v. Marle (C.A.vanMarle@inter.NL.net)
#### This hack makes an extra function in the "set members"
#### wich gives you the uppertunity to delete members
#### who have not posted for # days.
#### -->>-->>UPDATE<<--<<--
#### Now You Can Specify Number Of Posts TOO
# Some things may differ, because I've a very modified board...
# Sorry... If you can't find any thing, please mail me...
# BACK-UP all your files before editing!!!
# Don't blame me if your board's messed up
# All the edits are done in setmembers.cgi
>> change:
>> to:
>> change:
############### delete members who've not posted for specified # of days
sub deldatofpos {
$numofdays = $query -> param('daytodel');
$dirtoopen = "$ikondir" . "members";
opendir (DIR, "$dirtoopen");
@filedata = readdir(DIR);
closedir (DIR);
@sortedfile = sort(@filedata);
@sortedfile = grep(/cgi/,@sortedfile);
@sortedfile = sort alphabetically(@sortedfile);
$days = $numofdays * 24 * 60 * 60;
$now = time;
$deldate = $now - $days;
foreach (@sortedfile) {
unless ($_ eq "$ltr") {
$member = $_;
open (FILE, "$ikondir" . "members/" . "$_");
$todeldata = ;
close (FILE);
@totrash = split(/\|/,$todeldata);
$lastpostdate = @totrash[14];
($userinfo_POSTDATE, $userinfo_POSTURL, $userinfo_POSTTOPIC) = split(/\%%%/,$lastpostdate);
if ($userinfo_POSTDATE <= $deldate) {
push(@todelete,$_);
$memnam = $_;
$memnam =~ s/.cgi//ig;
$hisdate = &longdate($userinfo_POSTDATE);
$tempoutput .= qq~$memnam has made his/her last post on $hisdate ~;
}
$ltr = "$_";
}
}
$todelwithcomma = qq~~;
print qq~