mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-26 05:08:52 +00:00
merge some changes/fixes
henry: is your viewonline fix/change missing? ;) git-svn-id: file:///svn/phpbb/trunk@8503 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
82454165c3
commit
dbae1db24c
7 changed files with 43 additions and 34 deletions
|
@ -77,7 +77,7 @@ class posting_api
|
||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
// one transaction, we can now garuntee that atomicity of insertions
|
// one transaction, we can now garuntee that atomicity of insertions
|
||||||
$db->transaction('BEGIN');
|
$db->sql_transaction('begin');
|
||||||
|
|
||||||
$user_id = (int) $data['user_id'];
|
$user_id = (int) $data['user_id'];
|
||||||
$forum_id = (int) $data['forum_id'];
|
$forum_id = (int) $data['forum_id'];
|
||||||
|
@ -96,8 +96,7 @@ class posting_api
|
||||||
FROM ' . USERS_TABLE . '
|
FROM ' . USERS_TABLE . '
|
||||||
WHERE user_id = ' . $user_id;
|
WHERE user_id = ' . $user_id;
|
||||||
$result = $db->sql_query($sql);
|
$result = $db->sql_query($sql);
|
||||||
$row = $db->sql_fetchrow($result);
|
$username = (string) $db->sql_fetchfield('username');
|
||||||
$username = $row['username'];
|
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -125,7 +124,7 @@ class posting_api
|
||||||
'topic_posts' => 1,
|
'topic_posts' => 1,
|
||||||
'topic_moved_posts' => 0,
|
'topic_moved_posts' => 0,
|
||||||
'topic_deleted_posts' => 0,
|
'topic_deleted_posts' => 0,
|
||||||
'topic_unapproved_posts' => ($approved ? 0 : 1),
|
'topic_unapproved_posts' => ($approved) ? 0 : 1,
|
||||||
'topic_first_poster_name' => $username,
|
'topic_first_poster_name' => $username,
|
||||||
'topic_poster' => $user_id,
|
'topic_poster' => $user_id,
|
||||||
'topic_last_username' => $username,
|
'topic_last_username' => $username,
|
||||||
|
@ -179,14 +178,15 @@ class posting_api
|
||||||
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
|
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
|
||||||
|
|
||||||
// we are consistant, victory is ours
|
// we are consistant, victory is ours
|
||||||
$db->transaction('END');
|
$db->sql_transaction('commit');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function insert_post($data)
|
public function insert_post($data)
|
||||||
{
|
{
|
||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
// one transaction, we can now garuntee that atomicity of insertions
|
// one transaction, we can now garuntee that atomicity of insertions
|
||||||
$db->transaction('BEGIN');
|
$db->sql_transaction('begin');
|
||||||
|
|
||||||
$user_id = (int) $data['user_id'];
|
$user_id = (int) $data['user_id'];
|
||||||
$topic_id = (int) $data['topic_id'];
|
$topic_id = (int) $data['topic_id'];
|
||||||
|
@ -203,8 +203,7 @@ class posting_api
|
||||||
FROM ' . TOPICS_TABLE . '
|
FROM ' . TOPICS_TABLE . '
|
||||||
WHERE topic_id = ' . $topic_id;
|
WHERE topic_id = ' . $topic_id;
|
||||||
$result = $db->sql_query($sql);
|
$result = $db->sql_query($sql);
|
||||||
$row = $db->sql_fetchrow($result);
|
$forum_id = (int) $db->sql_fetchfield('forum_id');
|
||||||
$forum_id = (int) $row['forum_id'];
|
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -223,8 +222,7 @@ class posting_api
|
||||||
FROM ' . USERS_TABLE . '
|
FROM ' . USERS_TABLE . '
|
||||||
WHERE user_id = ' . $user_id;
|
WHERE user_id = ' . $user_id;
|
||||||
$result = $db->sql_query($sql);
|
$result = $db->sql_query($sql);
|
||||||
$row = $db->sql_fetchrow($result);
|
$username = (string) $db->sql_fetchfield('username');
|
||||||
$username = $row['username'];
|
|
||||||
$db->sql_freeresult($result);
|
$db->sql_freeresult($result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -298,7 +296,7 @@ class posting_api
|
||||||
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
|
$db->sql_handle_data('UPDATE', FORUMS_TABLE, $forum_data, "forum_id = $forum_id");
|
||||||
|
|
||||||
// we are consistant, victory is ours
|
// we are consistant, victory is ours
|
||||||
$db->transaction('END');
|
$db->sql_transaction('commit');
|
||||||
}
|
}
|
||||||
|
|
||||||
function move_topic($data)
|
function move_topic($data)
|
||||||
|
@ -306,7 +304,7 @@ class posting_api
|
||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
// lets get this party started
|
// lets get this party started
|
||||||
$db->transaction('BEGIN');
|
$db->sql_transaction('begin');
|
||||||
|
|
||||||
$topic_id = (int) $data['topic_id'];
|
$topic_id = (int) $data['topic_id'];
|
||||||
$to_forum_id = (int) $data['forum_id'];
|
$to_forum_id = (int) $data['forum_id'];
|
||||||
|
@ -317,6 +315,7 @@ class posting_api
|
||||||
WHERE topic_id = ' . $topic_id;
|
WHERE topic_id = ' . $topic_id;
|
||||||
$result = $db->sql_query($sql);
|
$result = $db->sql_query($sql);
|
||||||
$row = $db->sql_fetchrow($result);
|
$row = $db->sql_fetchrow($result);
|
||||||
|
$db->sql_freeresult($result);
|
||||||
|
|
||||||
$topic_status = (int) $row['topic_status'];
|
$topic_status = (int) $row['topic_status'];
|
||||||
$from_forum_id = (int) $row['from_forum_id'];
|
$from_forum_id = (int) $row['from_forum_id'];
|
||||||
|
@ -326,8 +325,6 @@ class posting_api
|
||||||
$topic_row['topic_deleted_posts'] = (int) $row['topic_deleted_posts'];
|
$topic_row['topic_deleted_posts'] = (int) $row['topic_deleted_posts'];
|
||||||
$topic_row['topic_unapproved_posts'] = (int) $row['topic_unapproved_posts'];
|
$topic_row['topic_unapproved_posts'] = (int) $row['topic_unapproved_posts'];
|
||||||
|
|
||||||
$db->sql_freeresult($result);
|
|
||||||
|
|
||||||
// let us first determine how many items we are removing from the pool
|
// let us first determine how many items we are removing from the pool
|
||||||
$sql = 'SELECT forum_posts, forum_moved_posts, forum_deleted_posts, forum_unapproved_posts, forum_id, forum_topics, forum_deleted_topics, forum_unapproved_topics
|
$sql = 'SELECT forum_posts, forum_moved_posts, forum_deleted_posts, forum_unapproved_posts, forum_id, forum_topics, forum_deleted_topics, forum_unapproved_topics
|
||||||
FROM ' . FORUMS_TABLE. '
|
FROM ' . FORUMS_TABLE. '
|
||||||
|
@ -448,7 +445,7 @@ class posting_api
|
||||||
|
|
||||||
// in hundreds of fewer lines of code, we have now moved a topic
|
// in hundreds of fewer lines of code, we have now moved a topic
|
||||||
// (this totally ignores the shadow topic thingy, I do not care for now)
|
// (this totally ignores the shadow topic thingy, I do not care for now)
|
||||||
$db->transaction('COMMIT');
|
$db->sql_transaction('commit');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -53,6 +53,7 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li><a href="#changelog">Changelog</a>
|
<li><a href="#changelog">Changelog</a>
|
||||||
<ol style="list-style-type: lower-roman;">
|
<ol style="list-style-type: lower-roman;">
|
||||||
|
<li><a href="#v301">Changes since 3.0.1</a></li>
|
||||||
<li><a href="#v300">Changes since 3.0.0</a></li>
|
<li><a href="#v300">Changes since 3.0.0</a></li>
|
||||||
<li><a href="#v30rc8">Changes since RC-8</a></li>
|
<li><a href="#v30rc8">Changes since RC-8</a></li>
|
||||||
<li><a href="#v30rc7">Changes since RC-7</a></li>
|
<li><a href="#v30rc7">Changes since RC-7</a></li>
|
||||||
|
@ -81,11 +82,17 @@
|
||||||
|
|
||||||
<div class="content">
|
<div class="content">
|
||||||
|
|
||||||
<a name="v300"></a><h3>1.i. Changes since 3.0.0</h3>
|
<a name="v301"></a><h3>1.i. Changes since 3.0.1</h3>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<li>[Fix] Ability to set permissions on non-mysql dbms (Bug #24955)</li>
|
||||||
|
<li>[Fix] Fixed blank style on setups having no username defined within config.php (Bug #25065)</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<a name="v300"></a><h3>1.ii. Changes since 3.0.0</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Change] Migrate phpBB to PHP versions >= 5.1</li>
|
<li>[Change] Migrate phpBB to PHP versions >= 5.1</li>
|
||||||
|
|
||||||
<li>[Change] Validate birthdays (Bug #15004)</li>
|
<li>[Change] Validate birthdays (Bug #15004)</li>
|
||||||
<li>[Fix] Allow correct avatar caching for CGI installations. (thanks wildbill)</li>
|
<li>[Fix] Allow correct avatar caching for CGI installations. (thanks wildbill)</li>
|
||||||
<li>[Fix] Fix disabling of word censor, now possible again</li>
|
<li>[Fix] Fix disabling of word censor, now possible again</li>
|
||||||
|
@ -148,9 +155,13 @@
|
||||||
<li>[Sec] Check for non-empty config.php within style.php (Report #s24575) - reported by bantu</li>
|
<li>[Sec] Check for non-empty config.php within style.php (Report #s24575) - reported by bantu</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
<<<<<<< .working
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc8"></a><h3>1.i. Changes since 3.0.RC8</h3>
|
<a name="v30rc8"></a><h3>1.i. Changes since 3.0.RC8</h3>
|
||||||
|
=======
|
||||||
|
<a name="v30rc8"></a><h3>1.iii. Changes since 3.0.RC8</h3>
|
||||||
|
>>>>>>> .merge-right.r8502
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] Cleaned usernames contain only single spaces, so "a_name" and "a__name" are treated as the same name (Bug #15634)</li>
|
<li>[Fix] Cleaned usernames contain only single spaces, so "a_name" and "a__name" are treated as the same name (Bug #15634)</li>
|
||||||
|
@ -159,7 +170,7 @@
|
||||||
<li>[Fix] Call garbage_collection() within database updater to correctly close connections (affects Oracle for example)</li>
|
<li>[Fix] Call garbage_collection() within database updater to correctly close connections (affects Oracle for example)</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc7"></a><h3>1.ii. Changes since 3.0.RC7</h3>
|
<a name="v30rc7"></a><h3>1.iv. Changes since 3.0.RC7</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] Fixed MSSQL related bug in the update system</li>
|
<li>[Fix] Fixed MSSQL related bug in the update system</li>
|
||||||
|
@ -194,7 +205,7 @@
|
||||||
<li>[Fix] No duplication of active topics (Bug #15474)</li>
|
<li>[Fix] No duplication of active topics (Bug #15474)</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc6"></a><h3>1.iii. Changes since 3.0.RC6</h3>
|
<a name="v30rc6"></a><h3>1.v. Changes since 3.0.RC6</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] Submitting language changes using acp_language (Bug #14736)</li>
|
<li>[Fix] Submitting language changes using acp_language (Bug #14736)</li>
|
||||||
|
@ -204,7 +215,7 @@
|
||||||
<li>[Fix] Able to request new password (Bug #14743)</li>
|
<li>[Fix] Able to request new password (Bug #14743)</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc5"></a><h3>1.iv. Changes since 3.0.RC5</h3>
|
<a name="v30rc5"></a><h3>1.vi. Changes since 3.0.RC5</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Feature] Removing constant PHPBB_EMBEDDED in favor of using an exit_handler(); the constant was meant to achive this more or less.</li>
|
<li>[Feature] Removing constant PHPBB_EMBEDDED in favor of using an exit_handler(); the constant was meant to achive this more or less.</li>
|
||||||
|
@ -267,7 +278,7 @@
|
||||||
<li>[Sec] New password hashing mechanism for storing passwords (#i42)</li>
|
<li>[Sec] New password hashing mechanism for storing passwords (#i42)</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc4"></a><h3>1.v. Changes since 3.0.RC4</h3>
|
<a name="v30rc4"></a><h3>1.vii. Changes since 3.0.RC4</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] MySQL, PostgreSQL and SQLite related database fixes (Bug #13862)</li>
|
<li>[Fix] MySQL, PostgreSQL and SQLite related database fixes (Bug #13862)</li>
|
||||||
|
@ -318,7 +329,7 @@
|
||||||
<li>[Fix] odbc_autocommit causing existing result sets to be dropped (Bug #14182)</li>
|
<li>[Fix] odbc_autocommit causing existing result sets to be dropped (Bug #14182)</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc3"></a><h3>1.vi. Changes since 3.0.RC3</h3>
|
<a name="v30rc3"></a><h3>1.viii. Changes since 3.0.RC3</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] Fixing some subsilver2 and prosilver style issues</li>
|
<li>[Fix] Fixing some subsilver2 and prosilver style issues</li>
|
||||||
|
@ -427,7 +438,7 @@
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc2"></a><h3>1.vii. Changes since 3.0.RC2</h3>
|
<a name="v30rc2"></a><h3>1.ix. Changes since 3.0.RC2</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] Re-allow searching within the memberlist</li>
|
<li>[Fix] Re-allow searching within the memberlist</li>
|
||||||
|
@ -473,7 +484,7 @@
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<a name="v30rc1"></a><h3>1.viii. Changes since 3.0.RC1</h3>
|
<a name="v30rc1"></a><h3>1.x. Changes since 3.0.RC1</h3>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
<li>[Fix] (X)HTML issues within the templates (Bug #11255, #11255)</li>
|
<li>[Fix] (X)HTML issues within the templates (Bug #11255, #11255)</li>
|
||||||
|
|
|
@ -273,13 +273,19 @@ class acp_attachments
|
||||||
{
|
{
|
||||||
$l_explain = (isset($user->lang[$vars['lang'] . '_EXPLAIN'])) ? $user->lang[$vars['lang'] . '_EXPLAIN'] : '';
|
$l_explain = (isset($user->lang[$vars['lang'] . '_EXPLAIN'])) ? $user->lang[$vars['lang'] . '_EXPLAIN'] : '';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$content = build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars);
|
||||||
|
if (empty($content))
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
$template->assign_block_vars('options', array(
|
$template->assign_block_vars('options', array(
|
||||||
'KEY' => $config_key,
|
'KEY' => $config_key,
|
||||||
'TITLE' => $user->lang[$vars['lang']],
|
'TITLE' => $user->lang[$vars['lang']],
|
||||||
'S_EXPLAIN' => $vars['explain'],
|
'S_EXPLAIN' => $vars['explain'],
|
||||||
'TITLE_EXPLAIN' => $l_explain,
|
'TITLE_EXPLAIN' => $l_explain,
|
||||||
'CONTENT' => build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars),
|
'CONTENT' => $content,
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
@ -565,7 +565,7 @@ class acp_board
|
||||||
'TITLE' => (isset($user->lang[$vars['lang']])) ? $user->lang[$vars['lang']] : $vars['lang'],
|
'TITLE' => (isset($user->lang[$vars['lang']])) ? $user->lang[$vars['lang']] : $vars['lang'],
|
||||||
'S_EXPLAIN' => $vars['explain'],
|
'S_EXPLAIN' => $vars['explain'],
|
||||||
'TITLE_EXPLAIN' => $l_explain,
|
'TITLE_EXPLAIN' => $l_explain,
|
||||||
'CONTENT' => build_cfg_template($type, $config_key, $this->new_config, $config_key, $vars),
|
'CONTENT' => $content,
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
@ -1156,7 +1156,7 @@ class acp_permissions
|
||||||
}
|
}
|
||||||
|
|
||||||
// Not ideal, due to the filesort, non-use of indexes, etc.
|
// Not ideal, due to the filesort, non-use of indexes, etc.
|
||||||
$sql = 'SELECT DISTINCT u.user_id, u.username
|
$sql = 'SELECT DISTINCT u.user_id, u.username, u.username_clean, u.user_regdate
|
||||||
FROM ' . USERS_TABLE . ' u, ' . ACL_USERS_TABLE . " a
|
FROM ' . USERS_TABLE . ' u, ' . ACL_USERS_TABLE . " a
|
||||||
WHERE u.user_id = a.user_id
|
WHERE u.user_id = a.user_id
|
||||||
$sql_forum_id
|
$sql_forum_id
|
||||||
|
|
|
@ -801,7 +801,7 @@ class auth
|
||||||
{
|
{
|
||||||
$this->_set_group_hold_ary($hold_ary[$row['forum_id']], $row['auth_option_id'], $row['auth_setting']);
|
$this->_set_group_hold_ary($hold_ary[$row['forum_id']], $row['auth_option_id'], $row['auth_setting']);
|
||||||
}
|
}
|
||||||
else
|
else if (!empty($this->role_cache[$row['auth_role_id']]))
|
||||||
{
|
{
|
||||||
foreach (unserialize($this->role_cache[$row['auth_role_id']]) as $option_id => $setting)
|
foreach (unserialize($this->role_cache[$row['auth_role_id']]) as $option_id => $setting)
|
||||||
{
|
{
|
||||||
|
|
|
@ -21,7 +21,7 @@ date_default_timezone_set('UTC');
|
||||||
|
|
||||||
require($phpbb_root_path . 'config.' . $phpEx);
|
require($phpbb_root_path . 'config.' . $phpEx);
|
||||||
|
|
||||||
if (!defined('PHPBB_INSTALLED') || empty($dbms) || !isset($dbhost) || !isset($dbpasswd) || empty($dbuser))
|
if (!defined('PHPBB_INSTALLED') || empty($dbms) || empty($acm_type))
|
||||||
{
|
{
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
@ -58,11 +58,6 @@ if (strspn($sid, 'abcdefABCDEF0123456789') !== strlen($sid))
|
||||||
// server a little
|
// server a little
|
||||||
if ($id)
|
if ($id)
|
||||||
{
|
{
|
||||||
if (empty($acm_type) || empty($dbms))
|
|
||||||
{
|
|
||||||
die('Hacking attempt');
|
|
||||||
}
|
|
||||||
|
|
||||||
// Include files
|
// Include files
|
||||||
require($phpbb_root_path . 'includes/acm/acm_' . $acm_type . '.' . $phpEx);
|
require($phpbb_root_path . 'includes/acm/acm_' . $acm_type . '.' . $phpEx);
|
||||||
require($phpbb_root_path . 'includes/cache.' . $phpEx);
|
require($phpbb_root_path . 'includes/cache.' . $phpEx);
|
||||||
|
|
Loading…
Add table
Reference in a new issue