1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-31 14:00:31 +02:00

add warning to ACP index if config file is writeable

git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8688 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2008-07-28 13:12:18 +00:00
parent 04814560c8
commit 0ce66e6552
3 changed files with 20 additions and 7 deletions

View File

@@ -168,7 +168,7 @@ class acp_main
$result = $db->sql_query($sql);
set_config('upload_dir_size', (int) $db->sql_fetchfield('stat'), true);
$db->sql_freeresult($result);
if (!function_exists('update_last_username'))
{
include($phpbb_root_path . "includes/functions_user.$phpEx");
@@ -199,7 +199,7 @@ class acp_main
add_log('admin', 'LOG_RESYNC_POSTCOUNTS');
break;
case 'date':
if (!$auth->acl_get('a_board'))
{
@@ -209,7 +209,7 @@ class acp_main
set_config('board_startdate', time() - 1);
add_log('admin', 'LOG_RESET_DATE');
break;
case 'db_track':
switch ($db->sql_layer)
{
@@ -231,7 +231,7 @@ class acp_main
FROM ' . FORUMS_TABLE . '
WHERE forum_type <> ' . FORUM_CAT;
$result = $db->sql_query($sql);
$forum_ids = array();
while ($row = $db->sql_fetchrow($result))
{
@@ -281,7 +281,7 @@ class acp_main
$db->sql_multi_insert(TOPICS_POSTED_TABLE, $sql_ary);
}
}
add_log('admin', 'LOG_RESYNC_POST_MARKING');
break;
@@ -320,7 +320,7 @@ class acp_main
$files_per_day = sprintf('%.2f', $total_files / $boarddays);
$upload_dir_size = get_formatted_filesize($config['upload_dir_size']);
$avatar_dir_size = 0;
if ($avatar_dir = @opendir($phpbb_root_path . $config['avatar_path']))
@@ -463,6 +463,11 @@ class acp_main
$template->assign_var('S_REMOVE_INSTALL', true);
}
if (file_exists($phpbb_root_path . 'config.' . $phpEx) && is_writeable($phpbb_root_path . 'config.' . $phpEx))
{
$template->assign_var('S_WRITEABLE_CONFIG', true);
}
$this->tpl_name = 'acp_main';
$this->page_title = 'ACP_MAIN';
}