1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-01 14:30:32 +02:00
git-svn-id: file:///svn/phpbb/trunk@977 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
James Atkinson
2001-09-03 08:04:26 +00:00
parent e515d617ed
commit 7d0d488f25
4 changed files with 74 additions and 64 deletions

View File

@@ -246,6 +246,10 @@ if(isset($mode)) // Are we supposed to do something?
if( $HTTP_POST_VARS['prune_enable'] == TRUE )
{
$new_forum_id = $db->sql_nextid();
if($HTTP_POST_VARS['prune_days'] == "" || $HTTP_POST_VARS['prune_freq'] == "")
{
message_die(GENERAL_ERROR, $lang['Set_prune_data'], $lang['Error']);
}
$sql = "INSERT INTO " . PRUNE_TABLE . " (forum_id, prune_days, prune_freq)
VALUES($new_forum_id, " . $HTTP_POST_VARS['prune_days'] . ", " . $HTTP_POST_VARS['prune_freq'] . ")";
@@ -273,6 +277,11 @@ if(isset($mode)) // Are we supposed to do something?
if($HTTP_POST_VARS['prune_enable'] == 1)
{
if($HTTP_POST_VARS['prune_days'] == "" || $HTTP_POST_VARS['prune_freq'] == "")
{
message_die(GENERAL_ERROR, $lang['Set_prune_data'], $lang['Error']);
}
$sql = "SELECT *
FROM " . PRUNE_TABLE . "
WHERE forum_id = " . $HTTP_POST_VARS['forum_id'];

View File

@@ -130,7 +130,7 @@ CREATE TABLE phpbb_config (
default_dateformat varchar(14) DEFAULT 'd M Y H:i' NOT NULL,
system_timezone int(11) DEFAULT '0' NOT NULL,
sys_template varchar(100) DEFAULT 'Default' NOT NULL,
prune_enable tinyint(1) DEFAULT '1' NOT NULL,
prune_enable tinyint(1) DEFAULT '0' NOT NULL,
gzip_compress tinyint(1) DEFAULT '0' NOT NULL,
PRIMARY KEY (config_id)
);

View File

@@ -125,7 +125,7 @@ CREATE TABLE phpbb_config (
smilies_path varchar(50) DEFAULT 'images/smiles' NOT NULL,
override_themes int2 NOT NULL,
flood_interval int NOT NULL,
prune_enable int2 DEFAULT '1' NOT NULL,
prune_enable int2 DEFAULT '0' NOT NULL,
gzip_compress int2 DEFAULT '0' NOT NULL,
CONSTRAINT phpbb_config_pkey PRIMARY KEY (config_id)
);

View File

@@ -843,6 +843,7 @@ $lang['reset_group_changes'] = "Reset Changes";
$lang['prune_days'] = 'Remove topics that haven\'t been posted to in';
$lang['prune_freq'] = 'Check for topic age every';
$lang['days'] = 'Days';
$lang['Set_prune_data'] = "You have turned on auto-prune for this forum but did not set a frequency or number of days to prune, please go back and do so";
//
// Word censor