1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-08 17:56:52 +02:00

- Documentation related changes

- added resend activation email dialog
- fixed issue in session code
- log failed/successful admin re-authentication/login
- fixed simple forum dropdown box (used in mcp and posting)


git-svn-id: file:///svn/phpbb/trunk@5114 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2005-04-09 12:26:45 +00:00
parent 0ba3f620d4
commit fc32df0358
110 changed files with 2212 additions and 1877 deletions

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_attachments.php
// STARTED : Sun Apr 20, 2003
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$filename = basename(__FILE__);
@@ -120,7 +119,7 @@ if ($mode == 'attach')
add_log('admin', 'LOG_' . strtoupper($mode) . '_CONFIG');
// Check Settings
test_upload($error, $new['upload_dir'], false);
test_upload($error, $new['upload_path'], false);
if (!sizeof($error))
{
@@ -420,7 +419,7 @@ if ($submit && $mode == 'orphan')
}
else
{
upload_file($row['post_id'], $row['topic_id'], $row['forum_id'], $config['upload_dir'], $upload_list[$row['post_id']]);
upload_file($row['post_id'], $row['topic_id'], $row['forum_id'], $config['upload_path'], $upload_list[$row['post_id']]);
}
}
unset($message_parser);
@@ -528,7 +527,7 @@ if ($mode == 'attach')
</tr>
<tr>
<td class="row1" width="40%"><b><?php echo $user->lang['UPLOAD_DIR']; ?>: </b><br /><span class="gensmall"><?php echo $user->lang['UPLOAD_DIR_EXPLAIN']; ?></span></td>
<td class="row2"><input type="text" size="25" maxlength="100" name="upload_dir" class="post" value="<?php echo $new['upload_dir'] ?>" /></td>
<td class="row2"><input type="text" size="25" maxlength="100" name="upload_path" class="post" value="<?php echo $new['upload_path'] ?>" /></td>
</tr>
<tr>
<td class="row1"><b><?php echo $user->lang['DISPLAY_ORDER']; ?>: </b><br /><span class="gensmall"><?php echo $user->lang['DISPLAY_ORDER_EXPLAIN']; ?></span></td>
@@ -1188,10 +1187,10 @@ if ($mode == 'orphan')
{
$attach_filelist = array();
$dir = @opendir($phpbb_root_path . $config['upload_dir']);
$dir = @opendir($phpbb_root_path . $config['upload_path']);
while ($file = @readdir($dir))
{
if (is_file($phpbb_root_path . $config['upload_dir'] . '/' . $file) && filesize($phpbb_root_path . $config['upload_dir'] . '/' . $file) && $file{0} != '.' && $file != 'index.htm' && !preg_match('#^thumb\_#', $file))
if (is_file($phpbb_root_path . $config['upload_path'] . '/' . $file) && filesize($phpbb_root_path . $config['upload_path'] . '/' . $file) && $file{0} != '.' && $file != 'index.htm' && !preg_match('#^thumb\_#', $file))
{
$attach_filelist[$file] = $file;
}
@@ -1243,12 +1242,12 @@ function marklist(match, name, status)
foreach ($attach_filelist as $file)
{
$row_class = (++$i % 2 == 0) ? 'row2' : 'row1';
$filesize = @filesize($phpbb_root_path . $config['upload_dir'] . '/' . $file);
$filesize = @filesize($phpbb_root_path . $config['upload_path'] . '/' . $file);
$size_lang = ($filesize >= 1048576) ? $user->lang['MB'] : ( ($filesize >= 1024) ? $user->lang['KB'] : $user->lang['BYTES'] );
$filesize = ($filesize >= 1048576) ? round((round($filesize / 1048576 * 100) / 100), 2) : (($filesize >= 1024) ? round((round($filesize / 1024 * 100) / 100), 2) : $filesize);
?>
<tr>
<td class="<?php echo $row_class; ?>"><a href="<?php echo $phpbb_root_path . $config['upload_dir'] . '/' . $file; ?>" class="gen" target="file"><?php echo $file; ?></a></td>
<td class="<?php echo $row_class; ?>"><a href="<?php echo $phpbb_root_path . $config['upload_path'] . '/' . $file; ?>" class="gen" target="file"><?php echo $file; ?></a></td>
<td class="<?php echo $row_class; ?>"><?php echo $filesize . ' ' . $size_lang; ?></td>
<td class="<?php echo $row_class; ?>"><b class="gen">ID: </b><input type="text" name="post_id[<?php echo $file; ?>]" class="post" size="7" maxlength="10" value="<?php echo (!empty($post_ids[$file])) ? $post_ids[$file] : ''; ?>" /></td>
<td class="<?php echo $row_class; ?>"><input type="checkbox" name="add[<?php echo $file; ?>]" /></td>
@@ -1399,7 +1398,7 @@ function download_select($select_name, $group_id = false)
return $group_select;
}
// Upload already uploaded file... huh? are you kidding?
/* Upload already uploaded file... huh? are you kidding?
function upload_file($post_id, $topic_id, $forum_id, $upload_dir, $filename)
{
global $message_parser, $db, $user, $phpbb_root_path;
@@ -1418,8 +1417,8 @@ function upload_file($post_id, $topic_id, $forum_id, $upload_dir, $filename)
'poster_id' => $user->data['user_id'],
'topic_id' => $topic_id,
'in_message' => 0,
'physical_filename' => $filedata['destination_filename'],
'real_filename' => $filedata['filename'],
'physical_filename' => $filedata['physical_filename'],
'real_filename' => $filedata['real_filename'],
'comment' => $message_parser->filename_data['filecomment'],
'extension' => $filedata['extension'],
'mimetype' => $filedata['mimetype'],
@@ -1459,6 +1458,7 @@ function upload_file($post_id, $topic_id, $forum_id, $upload_dir, $filename)
echo '<span style="color:red">' . sprintf($user->lang['ADMIN_UPLOAD_ERROR'], implode("<br />\t", $filedata['error'])) . '</span><br /><br />';
}
}
*/
// Search Imagick
function search_imagemagick()
@@ -1551,7 +1551,7 @@ function perform_site_list()
$ip_2_counter = ($ip_1_counter == $ip_range_explode[1]) ? $ip_range_explode[2] : 0;
$ip_2_end = ($ip_1_counter < $ip_1_end) ? 254 : $ip_range_explode[6];
if($ip_2_counter == 0 && $ip_2_end == 254)
if ($ip_2_counter == 0 && $ip_2_end == 254)
{
$ip_2_counter = 256;
$ip_2_fragment = 256;

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_ban.php
// STARTED : Tue Jul 31, 2001
// COPYRIGHT : <20> 2001,2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_ban'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_bbcodes.php
// STARTED : Wed Aug 20, 2003
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_bbcode'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_board.php
// STARTED : Thu Jul 12, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$filename = basename(__FILE__);

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_bots.php
// STARTED : Tue Oct 15, 2003
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_server'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_database.php
// STARTED : Thu May 31, 2001
// COPYRIGHT : <20> 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$filename = basename(__FILE__);

View File

@@ -1,24 +1,15 @@
<?php
/***************************************************************************
* admin_disallow.php
* -------------------
* begin : Tuesday, Oct 05, 2001
* copyright : (C) 2001 The phpBB Group
* email : support@phpbb.com
*
* $Id$
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_names'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_email.php
// STARTED : Thu May 31, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$file = basename(__FILE__);
@@ -161,10 +160,7 @@ if (isset($_POST['submit']))
}
unset($email_list);
if ($messenger->queue)
{
$messenger->queue->save();
}
$messenger->save_queue();
if ($group_id)
{

View File

@@ -1,22 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_forums.php
// STARTED : Thu Jul 12, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/*
TODO:
- make a function to verify and/or fix the tree?
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_gets('a_forum', 'a_forumadd', 'a_forumdel'))

View File

@@ -1,20 +1,17 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_groups.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2001,2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
// TODO
// Avatar gallery ...
// Mass user pref setting via group membership
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
* @todo Avatar gallery ...
* @todo Mass user pref setting via group membership
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_group'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_icons.php
// STARTED : Thu Mar 13, 2003
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_icons'))

View File

@@ -1,19 +1,16 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_jabber.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
// TODO
// Check/enter/update transport info
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
* @todo Check/enter/update transport info
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_server'))

View File

@@ -1,15 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_language.php
// STARTED : Sat Jan 23, 2005
// COPYRIGHT : <20> 2001,2005 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
// TODO:
// * new auth?

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_permissions.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$filename = basename(__FILE__);

View File

@@ -1,24 +1,15 @@
<?php
/***************************************************************************
* admin_board.php
* -------------------
* begin : Thursday, Jul 12, 2001
* copyright : (C) 2001 The phpBB Group
* email : support@phpbb.com
*
* $Id$
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
$module['GENERAL']['PHP_INFO'] = ($auth->acl_get('a_server')) ? basename(__FILE__) . $SID : '';

View File

@@ -1,15 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_profile.php
// STARTED : Sun Apr 20, 2003
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
/*
Remind if...

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_prune.php
// STARTED : Mon Jul 31, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_prune'))

View File

@@ -1,24 +1,15 @@
<?php
/***************************************************************************
* admin_prune_users.php
* -------------------
* begin : Saturday, Feb 13, 2001
* copyright : (C) 2001 The phpBB Group
* email : support@phpbb.com
*
* $Id$
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_userdel'))

View File

@@ -1,24 +1,15 @@
<?php
/***************************************************************************
* admin_ranks.php
* -------------------
* begin : Thursday, Jul 12, 2001
* copyright : (C) 2001 The phpBB Group
* email : support@phpbb.com
*
* $Id$
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_ranks'))

View File

@@ -1,24 +1,15 @@
<?php
/***************************************************************************
* admin_search.php
* -------------------
* begin : Saturday, Feb 13, 2001
* copyright : (C) 2001 The phpBB Group
* email : support@phpbb.com
*
* $Id$
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_search'))

View File

@@ -1,15 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_styles.php
// STARTED : Thu Aug 7 2003
// COPYRIGHT : <20> 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
// TODO
// For M-3

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_users.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2001,2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_gets('a_user', 'a_useradd', 'a_userdel'))
@@ -321,7 +320,7 @@ e_help = "<?php echo $user->lang['BBCODE_E_HELP']; ?>";
);
$messenger->send(NOTIFY_EMAIL);
$messenger->queue->save();
$messenger->save_queue();
add_log('admin', 'LOG_USER_REACTIVATE', $username);
add_log('user', $user_id, 'LOG_USER_REACTIVATE_USER');
@@ -2020,7 +2019,7 @@ if (!$auth->acl_get('a_user'))
adm_page_footer();
// Module class
/* Module class
class acp_admin_users extends module
{
@@ -2028,5 +2027,6 @@ class acp_admin_users extends module
}
*/
?>

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_viewlogs.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_'))
@@ -54,10 +53,7 @@ $sort_dir = request_var('sd', 'd');
// Define some vars depending on which logs we're looking at
$log_type = ($mode == 'admin') ? LOG_ADMIN : (($mode == 'mod') ? LOG_MOD : LOG_CRITICAL);
if ($log_type == LOG_MOD)
{
$user->add_lang('mcp');
}
$user->add_lang('mcp');
// Delete entries if requested and able
if (($deletemark || $deleteall) && $auth->acl_get('a_clearlogs'))
@@ -125,8 +121,24 @@ if ($mode == 'mod')
}
//
// Grab log data
//
$log_data = array();
$log_count = 0;
view_log($mode, $log_data, $log_count, $config['topics_per_page'], $start, $forum_id, 0, 0, $sql_where, $sql_sort);
?>
<table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">
<tr>
<td align="left" valign="top">&nbsp;<span class="nav"><?php echo on_page($log_count, $config['topics_per_page'], $start); ?></span></td>
<td align="right" valign="top" nowrap="nowrap">
<span class="nav"><?php echo generate_pagination("admin_viewlogs.$phpEx$SID&amp;mode=$mode&amp;$u_sort_param", $log_count, $config['topics_per_page'], $start, true); ?></span>
</td>
</tr>
</table>
<table class="bg" width="100%" cellpadding="4" cellspacing="1" border="0">
<tr>
<td class="cat" colspan="5" height="28" align="center"><?php echo $user->lang['DISPLAY_LOG']; ?>: &nbsp;<?php echo $s_limit_days; ?>&nbsp;<?php echo $user->lang['SORT_BY']; ?>: <?php echo $s_sort_key; ?> <?php echo $s_sort_dir; ?>&nbsp;<input class="btnlite" type="submit" value="<?php echo $user->lang['GO']; ?>" name="sort" /></td>
@@ -140,13 +152,6 @@ if ($mode == 'mod')
</tr>
<?php
//
// Grab log data
//
$log_data = array();
$log_count = 0;
view_log($mode, $log_data, $log_count, $config['topics_per_page'], $start, $forum_id, 0, 0, $sql_where, $sql_sort);
$row_class = '';
if ($log_count)
@@ -221,8 +226,8 @@ else
?><b><a href="javascript:marklist('list', true);"><?php echo $user->lang['MARK_ALL']; ?></a> :: <a href="javascript:marklist('list', false);"><?php echo $user->lang['UNMARK_ALL']; ?></a></b>&nbsp;<br /><br /><?php
}
echo generate_pagination("admin_viewlogs.$phpEx$SID&amp;mode=$mode&amp;$u_sort_param", $log_count, $config['topics_per_page'], $start);
echo generate_pagination("admin_viewlogs.$phpEx$SID&amp;mode=$mode&amp;$u_sort_param", $log_count, $config['topics_per_page'], $start, true);
?></span></td>
</tr>

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : admin_words.php
// STARTED : Thu Jul 12, 2001
// COPYRIGHT : <20> 2001, 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
if (!empty($setmodules))
{
if (!$auth->acl_get('a_words'))

View File

@@ -1,16 +1,15 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : adm/index.php
// STARTED : Sat Feb 13, 2001
// COPYRIGHT : <20> 2003 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
*/
define('IN_PHPBB', 1);
// Include files
$phpbb_root_path = './../';
@@ -205,10 +204,7 @@ elseif ($pane == 'right')
}
while ($row = $db->sql_fetchrow($result));
if ($messenger->queue)
{
$messenger->queue->save();
}
$messenger->save_queue();
unset($email_list);
@@ -283,7 +279,6 @@ elseif ($pane == 'right')
add_log('admin', 'LOG_RESYNC_STATS');
break;
// TODO: Temporary or a useful function?
case 'user':
if (!$auth->acl_get('a_defaults'))
{
@@ -291,40 +286,37 @@ elseif ($pane == 'right')
}
$post_count_ary = $auth->acl_getf('f_postcount');
$forum_ary = array();
foreach ($post_count_ary as $forum_id => $allowed)
{
if ($allowed['f_read'] && $allowed['f_postcount'])
if ($allowed['f_postcount'])
{
$forum_ary[] = $forum_id;
}
}
$post_count_sql = (sizeof($forum_ary)) ? 'AND f.forum_id IN (' . implode(', ', $forum_ary) . ')' : '';
unset($forum_ary, $post_count_ary);
$sql = 'SELECT user_id FROM ' . USERS_TABLE . '
WHERE user_type NOT IN (' . USER_INACTIVE . ')';
$result = $db->sql_query($sql);
while ($user_row = $db->sql_fetchrow($result))
if (!sizeof($forum_ary))
{
$user_id = (int) $user_row['user_id'];
$sql = 'SELECT COUNT(p.post_id) AS num_posts
FROM ' . POSTS_TABLE . ' p, ' . FORUMS_TABLE . ' f
WHERE p.poster_id = ' . $user_id . "
AND f.forum_id = p.forum_id
$post_count_sql";
$result2 = $db->sql_query($sql);
$num_real_posts = (int) $db->sql_fetchfield('num_posts', 0, $result2);
$db->sql_freeresult($result2);
$db->sql_query('UPDATE ' . USERS_TABLE . " SET user_posts = $num_real_posts WHERE user_id = $user_id");
$db->sql_query('UPDATE ' . USERS_TABLE . ' SET user_posts = 0');
}
$db->sql_freeresult($result);
else
{
$sql = 'SELECT COUNT(post_id) AS num_posts, poster_id
FROM ' . POSTS_TABLE . '
WHERE poster_id <> ' . ANONYMOUS . '
AND forum_id IN (' . implode(', ', $forum_ary) . ')
GROUP BY poster_id';
$result = $db->sql_query($sql);
add_log('admin', 'LOG_RESYNC_USER');
while ($row = $db->sql_fetchrow($result))
{
$db->sql_query('UPDATE ' . USERS_TABLE . " SET user_posts = {$row['num_posts']} WHERE user_id = {$row['poster_id']}");
}
$db->sql_freeresult($result);
}
add_log('admin', 'LOG_RESYNC_POSTCOUNTS');
break;
case 'date':
@@ -333,7 +325,7 @@ elseif ($pane == 'right')
trigger_error($user->lang['NO_ADMIN']);
}
set_config('board_startdate', time() - 1, true);
set_config('board_startdate', time() - 1);
add_log('admin', 'LOG_RESET_DATE');
break;
}
@@ -537,9 +529,8 @@ elseif ($pane == 'right')
<td class="row2">&nbsp;</td>
</tr>
<tr>
<td class="cat" colspan="4" align="right"><select name="action"><option value="online"><?php echo $user->lang['RESET_ONLINE']; ?></option><option value="date"><?php echo $user->lang['RESET_DATE']; ?></option><option value="stats"><?php echo $user->lang['RESYNC_STATS']; ?></option>
<!-- option value="user"><?php echo $user->lang['RESYNC_USER_POSTS']; ?></option -->
</select> <input class="btnlite" type="submit" name="submit" value="<?php echo $user->lang['SUBMIT']; ?>" />&nbsp;</td>
<td class="cat" colspan="4" align="right"><select name="action"><option value="online"><?php echo $user->lang['RESET_ONLINE']; ?></option><option value="date"><?php echo $user->lang['RESET_DATE']; ?></option><option value="stats"><?php echo $user->lang['RESYNC_STATS']; ?></option><option value="user"><?php echo $user->lang['RESYNC_POSTCOUNTS']; ?></option>
</select> <input class="btnlite" type="submit" name="submit" value="<?php echo $user->lang['SUBMIT']; ?>" />&nbsp;</td>
</tr>
</table></form>

View File

@@ -1,21 +1,20 @@
<?php
// -------------------------------------------------------------
//
// $Id$
//
// FILENAME : pagestart.php
// STARTED : Thu Aug 2, 2001
// COPYRIGHT : <20> 2001, 2004 phpBB Group
// WWW : http://www.phpbb.com/
// LICENCE : GPL vs2.0 [ see /docs/COPYING ]
//
// -------------------------------------------------------------
/**
*
* @package acp
* @version $Id$
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
if (!defined('IN_PHPBB'))
{
exit;
}
/**
*/
define('NEED_SID', true);
define('IN_ADMIN', true);
require($phpbb_root_path . 'common.'.$phpEx);
@@ -324,7 +323,10 @@ function build_cfg_template($tpl_type, $config_key, $options = '')
}
// General ACP module class
/**
* @package acp
* General ACP module class
*/
class module
{
var $id = 0;