mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-06 16:56:44 +02:00
Merge branch 'develop' of github.com:phpbb/phpbb3 into ticket/11103
# By Oleg Pudeyev (37) and others # Via Oleg Pudeyev (24) and others * 'develop' of github.com:phpbb/phpbb3: (179 commits) [ticket/11323] Add tests for inclusion of defined variables [ticket/11324] Add PHP 5.5 environment to travis and allow it to fail. [ticket/11321] Recreate schema files with develop/create_schema_files.php [ticket/11320] Include functions file as we need phpbb_convert_30_dbms_to_31 [ticket/11313] Use correct object el instead of eel in alt_text callback [ticket/11301] Guidelines: Add spaces in front and after the / operator. [ticket/11301] Explicitly cast str offset to int to prevent E_NOTICE on 5.4. [ticket/11311] Include asset core.js in subsilver2 overall_footer.html [ticket/10949] Remove not needed comma [ticket/11309] phpbb_extension_interface::disable_step correct docblock. [ticket/10949] Converted missing code to new JS coding guidelines [ticket/11302] Correctly select first timezone or selected timezone [ticket/11305] Mock container for cache driver in functional create_user() [ticket/11305] Check for $cache being null before using it in db drivers. [ticket/10805] Compare phpbbAlertTimer against null [ticket/11305] Define hook finder as a service on the container. [ticket/11305] Adjust comment. [ticket/11305] Use phpbb_create_default_container. [ticket/11305] Create a normal container during final installation step. [ticket/11305] Retrieve cache driver from container rather than cache service. ... Conflicts: phpBB/install/schemas/firebird_schema.sql phpBB/install/schemas/mssql_schema.sql phpBB/install/schemas/mysql_40_schema.sql phpBB/install/schemas/mysql_41_schema.sql phpBB/install/schemas/oracle_schema.sql phpBB/install/schemas/postgres_schema.sql phpBB/install/schemas/sqlite_schema.sql phpBB/styles/subsilver2/template/overall_footer.html
This commit is contained in:
@@ -73,6 +73,10 @@ if (!defined('PHPBB_INSTALLED') || empty($dbms) || empty($acm_type))
|
||||
die("Please read: <a href='../docs/INSTALL.html'>INSTALL.html</a> before attempting to update.");
|
||||
}
|
||||
|
||||
// In case $phpbb_adm_relative_path is not set (in case of an update), use the default.
|
||||
$phpbb_adm_relative_path = (isset($phpbb_adm_relative_path)) ? $phpbb_adm_relative_path : 'adm/';
|
||||
$phpbb_admin_path = (defined('PHPBB_ADMIN_PATH')) ? PHPBB_ADMIN_PATH : $phpbb_root_path . $phpbb_adm_relative_path;
|
||||
|
||||
// Include files
|
||||
require($phpbb_root_path . 'includes/class_loader.' . $phpEx);
|
||||
|
||||
@@ -117,18 +121,7 @@ $phpbb_class_loader_ext = new phpbb_class_loader('phpbb_ext_', "{$phpbb_root_pat
|
||||
$phpbb_class_loader_ext->register();
|
||||
|
||||
// Set up container
|
||||
$phpbb_container = phpbb_create_dumped_container_unless_debug(
|
||||
array(
|
||||
new phpbb_di_extension_config($phpbb_root_path . 'config.' . $phpEx),
|
||||
new phpbb_di_extension_core($phpbb_root_path),
|
||||
),
|
||||
array(
|
||||
new phpbb_di_pass_collection_pass(),
|
||||
new phpbb_di_pass_kernel_pass(),
|
||||
),
|
||||
$phpbb_root_path,
|
||||
$phpEx
|
||||
);
|
||||
$phpbb_container = phpbb_create_default_container($phpbb_root_path, $phpEx);
|
||||
|
||||
$phpbb_class_loader->set_cache($phpbb_container->get('cache.driver'));
|
||||
$phpbb_class_loader_ext->set_cache($phpbb_container->get('cache.driver'));
|
||||
@@ -152,7 +145,8 @@ if (file_exists($phpbb_root_path . 'includes/hooks/index.' . $phpEx))
|
||||
require($phpbb_root_path . 'includes/hooks/index.' . $phpEx);
|
||||
$phpbb_hook = new phpbb_hook(array('exit_handler', 'phpbb_user_session_handler', 'append_sid', array('template', 'display')));
|
||||
|
||||
foreach ($cache->obtain_hooks() as $hook)
|
||||
$phpbb_hook_finder = $phpbb_container->get('hook_finder');
|
||||
foreach ($phpbb_hook_finder->find() as $hook)
|
||||
{
|
||||
@include($phpbb_root_path . 'includes/hooks/' . $hook . '.' . $phpEx);
|
||||
}
|
||||
@@ -205,7 +199,7 @@ include($phpbb_root_path . 'language/' . $language . '/install.' . $phpEx);
|
||||
$inline_update = (request_var('type', 0)) ? true : false;
|
||||
|
||||
// To let set_config() calls succeed, we need to make the config array available globally
|
||||
$config = new phpbb_config_db($db, $cache->get_driver(), CONFIG_TABLE);
|
||||
$config = new phpbb_config_db($db, $phpbb_container->get('cache.driver'), CONFIG_TABLE);
|
||||
set_config(null, null, null, $config);
|
||||
set_config_count(null, null, null, $config);
|
||||
|
||||
@@ -243,7 +237,7 @@ if ($has_global && !$ga_forum_id)
|
||||
|
||||
<title><?php echo $lang['UPDATING_TO_LATEST_STABLE']; ?></title>
|
||||
|
||||
<link href="../adm/style/admin.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<link href="<?php echo htmlspecialchars($phpbb_admin_path); ?>style/admin.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
|
||||
</head>
|
||||
|
||||
@@ -293,7 +287,7 @@ header('Content-type: text/html; charset=UTF-8');
|
||||
|
||||
<title><?php echo $lang['UPDATING_TO_LATEST_STABLE']; ?></title>
|
||||
|
||||
<link href="../adm/style/admin.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
<link href="<?php echo htmlspecialchars($phpbb_admin_path); ?>style/admin.css" rel="stylesheet" type="text/css" media="screen" />
|
||||
|
||||
</head>
|
||||
|
||||
@@ -592,7 +586,7 @@ else
|
||||
add_log('admin', 'LOG_UPDATE_DATABASE', $orig_version, $updates_to_version);
|
||||
|
||||
// Now we purge the session table as well as all cache files
|
||||
$cache->purge();
|
||||
$phpbb_container->get('cache.driver')->purge();
|
||||
|
||||
_print_footer();
|
||||
|
||||
@@ -1237,9 +1231,12 @@ function database_update_info()
|
||||
'style_parent_tree' => array('TEXT', ''),
|
||||
),
|
||||
REPORTS_TABLE => array(
|
||||
'reported_post_text' => array('MTEXT_UNI', ''),
|
||||
'reported_post_uid' => array('VCHAR:8', ''),
|
||||
'reported_post_bitfield' => array('VCHAR:255', ''),
|
||||
'reported_post_text' => array('MTEXT_UNI', ''),
|
||||
'reported_post_uid' => array('VCHAR:8', ''),
|
||||
'reported_post_bitfield' => array('VCHAR:255', ''),
|
||||
'reported_post_enable_bbcode' => array('BOOL', 1),
|
||||
'reported_post_enable_smilies' => array('BOOL', 1),
|
||||
'reported_post_enable_magic_url' => array('BOOL', 1),
|
||||
),
|
||||
),
|
||||
'change_columns' => array(
|
||||
@@ -1261,7 +1258,7 @@ function database_update_info()
|
||||
*****************************************************************************/
|
||||
function change_database_data(&$no_updates, $version)
|
||||
{
|
||||
global $db, $errored, $error_ary, $config, $phpbb_root_path, $phpEx, $db_tools;
|
||||
global $db, $db_tools, $errored, $error_ary, $config, $table_prefix, $phpbb_root_path, $phpEx;
|
||||
|
||||
$update_helpers = new phpbb_update_helpers();
|
||||
|
||||
@@ -1578,8 +1575,6 @@ function change_database_data(&$no_updates, $version)
|
||||
),
|
||||
);
|
||||
|
||||
global $db_tools;
|
||||
|
||||
$statements = $db_tools->perform_schema_changes($changes);
|
||||
|
||||
foreach ($statements as $sql)
|
||||
@@ -2221,26 +2216,41 @@ function change_database_data(&$no_updates, $version)
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
global $db_tools, $table_prefix;
|
||||
|
||||
// Recover from potentially broken Q&A CAPTCHA table on firebird
|
||||
// Q&A CAPTCHA was uninstallable, so it's safe to remove these
|
||||
// without data loss
|
||||
/*
|
||||
* Due to a bug, vanilla phpbb could not create captcha tables
|
||||
* in 3.0.8 on firebird. It was possible for board administrators
|
||||
* to adjust the code to work. If code was manually adjusted by
|
||||
* board administrators, index names would not be the same as
|
||||
* what 3.0.9 and newer expect. This code fragment drops captcha
|
||||
* tables, destroying all entered Q&A captcha configuration, such
|
||||
* that when Q&A is configured next the respective tables will be
|
||||
* created with correct index names.
|
||||
*
|
||||
* If you wish to preserve your Q&A captcha configuration, you can
|
||||
* manually rename indexes to the currently expected name:
|
||||
* phpbb_captcha_questions_lang_iso => phpbb_captcha_questions_lang
|
||||
* phpbb_captcha_answers_question_id => phpbb_captcha_answers_qid
|
||||
*
|
||||
* Again, this needs to be done only if a board was manually modified
|
||||
* to fix broken captcha code.
|
||||
*
|
||||
if ($db_tools->sql_layer == 'firebird')
|
||||
{
|
||||
$tables = array(
|
||||
$table_prefix . 'captcha_questions',
|
||||
$table_prefix . 'captcha_answers',
|
||||
$table_prefix . 'qa_confirm',
|
||||
$changes = array(
|
||||
'drop_tables' => array(
|
||||
$table_prefix . 'captcha_questions',
|
||||
$table_prefix . 'captcha_answers',
|
||||
$table_prefix . 'qa_confirm',
|
||||
),
|
||||
);
|
||||
foreach ($tables as $table)
|
||||
$statements = $db_tools->perform_schema_changes($changes);
|
||||
|
||||
foreach ($statements as $sql)
|
||||
{
|
||||
if ($db_tools->sql_table_exists($table))
|
||||
{
|
||||
$db_tools->sql_table_drop($table);
|
||||
}
|
||||
_sql($sql, $errored, $error_ary);
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
$no_updates = false;
|
||||
break;
|
||||
@@ -2950,7 +2960,11 @@ function change_database_data(&$no_updates, $version)
|
||||
set_config('board_timezone', $update_helpers->convert_phpbb30_timezone($config['board_timezone'], $config['board_dst']));
|
||||
|
||||
// After we have calculated the timezones we can delete user_dst column from user table.
|
||||
$db_tools->sql_column_remove(USERS_TABLE, 'user_dst');
|
||||
$statements = $db_tools->sql_column_remove(USERS_TABLE, 'user_dst');
|
||||
foreach ($statements as $sql)
|
||||
{
|
||||
_sql($sql, $errored, $error_ary);
|
||||
}
|
||||
}
|
||||
|
||||
if (!isset($config['site_home_url']))
|
||||
@@ -3046,6 +3060,7 @@ function change_database_data(&$no_updates, $version)
|
||||
_sql($sql, $errored, $error_ary);
|
||||
}
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
|
||||
// Add new permissions
|
||||
include_once($phpbb_root_path . 'includes/acp/auth.' . $phpEx);
|
||||
|
@@ -73,6 +73,10 @@ else
|
||||
}
|
||||
@ini_set('memory_limit', $mem_limit);
|
||||
|
||||
// In case $phpbb_adm_relative_path is not set (in case of an update), use the default.
|
||||
$phpbb_adm_relative_path = (isset($phpbb_adm_relative_path)) ? $phpbb_adm_relative_path : 'adm/';
|
||||
$phpbb_admin_path = (defined('PHPBB_ADMIN_PATH')) ? PHPBB_ADMIN_PATH : $phpbb_root_path . $phpbb_adm_relative_path;
|
||||
|
||||
// Include essential scripts
|
||||
require($phpbb_root_path . 'includes/class_loader.' . $phpEx);
|
||||
|
||||
@@ -97,9 +101,6 @@ $phpbb_container = phpbb_create_install_container($phpbb_root_path, $phpEx);
|
||||
$phpbb_class_loader->set_cache($phpbb_container->get('cache.driver'));
|
||||
$phpbb_class_loader_ext->set_cache($phpbb_container->get('cache.driver'));
|
||||
|
||||
// set up caching
|
||||
$cache = $phpbb_container->get('cache');
|
||||
|
||||
$phpbb_dispatcher = $phpbb_container->get('dispatcher');
|
||||
$request = $phpbb_container->get('request');
|
||||
|
||||
@@ -195,7 +196,8 @@ if (file_exists($phpbb_root_path . 'includes/hooks/index.' . $phpEx))
|
||||
require($phpbb_root_path . 'includes/hooks/index.' . $phpEx);
|
||||
$phpbb_hook = new phpbb_hook(array('exit_handler', 'phpbb_user_session_handler', 'append_sid', array('template', 'display')));
|
||||
|
||||
foreach ($cache->obtain_hooks() as $hook)
|
||||
$phpbb_hook_finder = $phpbb_container->get('hook_finder');
|
||||
foreach ($phpbb_hook_finder->find() as $hook)
|
||||
{
|
||||
@include($phpbb_root_path . 'includes/hooks/' . $hook . '.' . $phpEx);
|
||||
}
|
||||
@@ -215,9 +217,9 @@ $phpbb_style_path_provider = new phpbb_style_path_provider();
|
||||
$template = new phpbb_template($phpbb_root_path, $phpEx, $config, $user, $phpbb_style_resource_locator, new phpbb_template_context());
|
||||
$phpbb_style = new phpbb_style($phpbb_root_path, $phpEx, $config, $user, $phpbb_style_resource_locator, $phpbb_style_path_provider, $template);
|
||||
$phpbb_style->set_ext_dir_prefix('adm/');
|
||||
$phpbb_style->set_custom_style('admin', '../adm/style', array(), '');
|
||||
$phpbb_style->set_custom_style('admin', $phpbb_admin_path . 'style', array(), '');
|
||||
$template->assign_var('T_ASSETS_PATH', '../assets');
|
||||
$template->assign_var('T_TEMPLATE_PATH', '../adm/style');
|
||||
$template->assign_var('T_TEMPLATE_PATH', $phpbb_admin_path . 'style');
|
||||
|
||||
$install = new module();
|
||||
|
||||
@@ -361,7 +363,7 @@ class module
|
||||
}
|
||||
|
||||
define('HEADER_INC', true);
|
||||
global $template, $lang, $stage, $phpbb_root_path;
|
||||
global $template, $lang, $stage, $phpbb_root_path, $phpbb_admin_path;
|
||||
|
||||
$template->assign_vars(array(
|
||||
'L_CHANGE' => $lang['CHANGE'],
|
||||
@@ -370,7 +372,7 @@ class module
|
||||
'L_SELECT_LANG' => $lang['SELECT_LANG'],
|
||||
'L_SKIP' => $lang['SKIP'],
|
||||
'PAGE_TITLE' => $this->get_page_title(),
|
||||
'T_IMAGE_PATH' => $phpbb_root_path . 'adm/images/',
|
||||
'T_IMAGE_PATH' => htmlspecialchars($phpbb_admin_path) . 'images/',
|
||||
|
||||
'S_CONTENT_DIRECTION' => $lang['DIRECTION'],
|
||||
'S_CONTENT_FLOW_BEGIN' => ($lang['DIRECTION'] == 'ltr') ? 'left' : 'right',
|
||||
@@ -551,7 +553,7 @@ class module
|
||||
*/
|
||||
function error($error, $line, $file, $skip = false)
|
||||
{
|
||||
global $lang, $db, $template;
|
||||
global $lang, $db, $template, $phpbb_admin_path;
|
||||
|
||||
if ($skip)
|
||||
{
|
||||
@@ -573,7 +575,7 @@ class module
|
||||
echo '<head>';
|
||||
echo '<meta charset="utf-8">';
|
||||
echo '<title>' . $lang['INST_ERR_FATAL'] . '</title>';
|
||||
echo '<link href="../adm/style/admin.css" rel="stylesheet" type="text/css" media="screen" />';
|
||||
echo '<link href="' . htmlspecialchars($phpbb_admin_path) . 'style/admin.css" rel="stylesheet" type="text/css" media="screen" />';
|
||||
echo '</head>';
|
||||
echo '<body id="errorpage">';
|
||||
echo '<div id="wrap">';
|
||||
|
@@ -1538,6 +1538,7 @@ class install_convert extends module
|
||||
function finish_conversion()
|
||||
{
|
||||
global $db, $phpbb_root_path, $phpEx, $convert, $config, $language, $user, $template;
|
||||
global $cache, $auth;
|
||||
|
||||
$db->sql_query('DELETE FROM ' . CONFIG_TABLE . "
|
||||
WHERE config_name = 'convert_progress'
|
||||
@@ -1547,7 +1548,7 @@ class install_convert extends module
|
||||
$db->sql_query('DELETE FROM ' . SESSIONS_TABLE);
|
||||
|
||||
@unlink($phpbb_root_path . 'cache/data_global.' . $phpEx);
|
||||
cache_moderators();
|
||||
phpbb_cache_moderators($db, $cache, $auth);
|
||||
|
||||
// And finally, add a note to the log
|
||||
add_log('admin', 'LOG_INSTALL_CONVERTED', $convert->convertor_data['forum_name'], $config['version']);
|
||||
|
@@ -52,12 +52,13 @@ class install_install extends module
|
||||
|
||||
function main($mode, $sub)
|
||||
{
|
||||
global $lang, $template, $language, $phpbb_root_path, $cache;
|
||||
global $lang, $template, $language, $phpbb_root_path, $phpEx;
|
||||
global $phpbb_container, $cache;
|
||||
|
||||
switch ($sub)
|
||||
{
|
||||
case 'intro':
|
||||
$cache->purge();
|
||||
$phpbb_container->get('cache.driver')->purge();
|
||||
|
||||
$this->page_title = $lang['SUB_INTRO'];
|
||||
|
||||
@@ -101,6 +102,12 @@ class install_install extends module
|
||||
break;
|
||||
|
||||
case 'final':
|
||||
// Create a normal container now
|
||||
$phpbb_container = phpbb_create_default_container($phpbb_root_path, $phpEx);
|
||||
|
||||
// Sets the global $cache variable
|
||||
$cache = $phpbb_container->get('cache');
|
||||
|
||||
$this->build_search_index($mode, $sub);
|
||||
$this->add_modules($mode, $sub);
|
||||
$this->add_language($mode, $sub);
|
||||
@@ -1807,7 +1814,7 @@ class install_install extends module
|
||||
*/
|
||||
function email_admin($mode, $sub)
|
||||
{
|
||||
global $auth, $config, $db, $lang, $template, $user, $phpbb_root_path, $phpEx;
|
||||
global $auth, $config, $db, $lang, $template, $user, $phpbb_root_path, $phpbb_admin_path, $phpEx;
|
||||
|
||||
$this->page_title = $lang['STAGE_FINAL'];
|
||||
|
||||
@@ -1854,7 +1861,7 @@ class install_install extends module
|
||||
'TITLE' => $lang['INSTALL_CONGRATS'],
|
||||
'BODY' => sprintf($lang['INSTALL_CONGRATS_EXPLAIN'], $config['version'], append_sid($phpbb_root_path . 'install/index.' . $phpEx, 'mode=convert&language=' . $data['language']), '../docs/README.html'),
|
||||
'L_SUBMIT' => $lang['INSTALL_LOGIN'],
|
||||
'U_ACTION' => append_sid($phpbb_root_path . 'adm/index.' . $phpEx, 'i=send_statistics&mode=send_statistics'),
|
||||
'U_ACTION' => append_sid($phpbb_admin_path . 'index.' . $phpEx, 'i=send_statistics&mode=send_statistics'),
|
||||
));
|
||||
}
|
||||
|
||||
|
@@ -72,7 +72,7 @@ class install_update extends module
|
||||
function main($mode, $sub)
|
||||
{
|
||||
global $phpbb_style, $template, $phpEx, $phpbb_root_path, $user, $db, $config, $cache, $auth, $language;
|
||||
global $request;
|
||||
global $request, $phpbb_admin_path, $phpbb_adm_relative_path;
|
||||
|
||||
$this->tpl_name = 'install_update';
|
||||
$this->page_title = 'UPDATE_INSTALLATION';
|
||||
@@ -132,7 +132,7 @@ class install_update extends module
|
||||
}
|
||||
|
||||
// Set custom template again. ;)
|
||||
$phpbb_style->set_custom_style('admin', '../adm/style', array(), '');
|
||||
$phpbb_style->set_custom_style('admin', $phpbb_admin_path . 'style', array(), '');
|
||||
|
||||
$template->assign_vars(array(
|
||||
'S_USER_LANG' => $user->lang['USER_LANG'],
|
||||
@@ -217,7 +217,7 @@ class install_update extends module
|
||||
if ($this->test_update === false)
|
||||
{
|
||||
// Got the updater template itself updated? If so, we are able to directly use it - but only if all three files are present
|
||||
if (in_array('adm/style/install_update.html', $this->update_info['files']))
|
||||
if (in_array($phpbb_adm_relative_path . 'style/install_update.html', $this->update_info['files']))
|
||||
{
|
||||
$this->tpl_name = '../../install/update/new/adm/style/install_update';
|
||||
}
|
||||
@@ -494,6 +494,7 @@ class install_update extends module
|
||||
$template->assign_vars(array(
|
||||
'S_FILE_CHECK' => true,
|
||||
'S_ALL_UP_TO_DATE' => $all_up_to_date,
|
||||
'L_ALL_FILES_UP_TO_DATE' => $user->lang('ALL_FILES_UP_TO_DATE', append_sid("{$phpbb_root_path}ucp.$phpEx", 'mode=login'), append_sid("{$phpbb_root_path}ucp.$phpEx", 'mode=login&redirect=' . $phpbb_adm_relative_path . 'index.php%3Fi=send_statistics%26mode=send_statistics')),
|
||||
'S_VERSION_UP_TO_DATE' => $up_to_date,
|
||||
'U_ACTION' => append_sid($this->p_master->module_url, "language=$language&mode=$mode&sub=file_check"),
|
||||
'U_UPDATE_ACTION' => append_sid($this->p_master->module_url, "language=$language&mode=$mode&sub=update_files"),
|
||||
@@ -1078,12 +1079,12 @@ class install_update extends module
|
||||
*/
|
||||
function show_diff(&$update_list)
|
||||
{
|
||||
global $phpbb_root_path, $template, $user;
|
||||
global $phpbb_root_path, $template, $user, $phpbb_adm_relative_path;
|
||||
|
||||
$this->tpl_name = 'install_update_diff';
|
||||
|
||||
// Got the diff template itself updated? If so, we are able to directly use it
|
||||
if (in_array('adm/style/install_update_diff.html', $this->update_info['files']))
|
||||
if (in_array($phpbb_adm_relative_path . 'style/install_update_diff.html', $this->update_info['files']))
|
||||
{
|
||||
$this->tpl_name = '../../install/update/new/adm/style/install_update_diff';
|
||||
}
|
||||
|
@@ -950,7 +950,10 @@ CREATE TABLE phpbb_reports (
|
||||
report_text BLOB SUB_TYPE TEXT CHARACTER SET UTF8 DEFAULT '' NOT NULL,
|
||||
reported_post_text BLOB SUB_TYPE TEXT CHARACTER SET UTF8 DEFAULT '' NOT NULL,
|
||||
reported_post_uid VARCHAR(8) CHARACTER SET NONE DEFAULT '' NOT NULL,
|
||||
reported_post_bitfield VARCHAR(255) CHARACTER SET NONE DEFAULT '' NOT NULL
|
||||
reported_post_bitfield VARCHAR(255) CHARACTER SET NONE DEFAULT '' NOT NULL,
|
||||
reported_post_enable_magic_url INTEGER DEFAULT 1 NOT NULL,
|
||||
reported_post_enable_smilies INTEGER DEFAULT 1 NOT NULL,
|
||||
reported_post_enable_bbcode INTEGER DEFAULT 1 NOT NULL
|
||||
);;
|
||||
|
||||
ALTER TABLE phpbb_reports ADD PRIMARY KEY (report_id);;
|
||||
|
@@ -1159,7 +1159,10 @@ CREATE TABLE [phpbb_reports] (
|
||||
[report_text] [text] DEFAULT ('') NOT NULL ,
|
||||
[reported_post_text] [text] DEFAULT ('') NOT NULL ,
|
||||
[reported_post_uid] [varchar] (8) DEFAULT ('') NOT NULL ,
|
||||
[reported_post_bitfield] [varchar] (255) DEFAULT ('') NOT NULL
|
||||
[reported_post_bitfield] [varchar] (255) DEFAULT ('') NOT NULL ,
|
||||
[reported_post_enable_magic_url] [int] DEFAULT (1) NOT NULL ,
|
||||
[reported_post_enable_smilies] [int] DEFAULT (1) NOT NULL ,
|
||||
[reported_post_enable_bbcode] [int] DEFAULT (1) NOT NULL
|
||||
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
|
||||
GO
|
||||
|
||||
|
@@ -675,6 +675,9 @@ CREATE TABLE phpbb_reports (
|
||||
reported_post_text mediumblob NOT NULL,
|
||||
reported_post_uid varbinary(8) DEFAULT '' NOT NULL,
|
||||
reported_post_bitfield varbinary(255) DEFAULT '' NOT NULL,
|
||||
reported_post_enable_magic_url tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_smilies tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_bbcode tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
PRIMARY KEY (report_id),
|
||||
KEY post_id (post_id),
|
||||
KEY pm_id (pm_id)
|
||||
|
@@ -675,6 +675,9 @@ CREATE TABLE phpbb_reports (
|
||||
reported_post_text mediumtext NOT NULL,
|
||||
reported_post_uid varchar(8) DEFAULT '' NOT NULL,
|
||||
reported_post_bitfield varchar(255) DEFAULT '' NOT NULL,
|
||||
reported_post_enable_magic_url tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_smilies tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_bbcode tinyint(1) UNSIGNED DEFAULT '1' NOT NULL,
|
||||
PRIMARY KEY (report_id),
|
||||
KEY post_id (post_id),
|
||||
KEY pm_id (pm_id)
|
||||
|
@@ -1266,6 +1266,9 @@ CREATE TABLE phpbb_reports (
|
||||
reported_post_text clob DEFAULT '' ,
|
||||
reported_post_uid varchar2(8) DEFAULT '' ,
|
||||
reported_post_bitfield varchar2(255) DEFAULT '' ,
|
||||
reported_post_enable_magic_url number(1) DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_smilies number(1) DEFAULT '1' NOT NULL,
|
||||
reported_post_enable_bbcode number(1) DEFAULT '1' NOT NULL,
|
||||
CONSTRAINT pk_phpbb_reports PRIMARY KEY (report_id)
|
||||
)
|
||||
/
|
||||
|
@@ -887,6 +887,9 @@ CREATE TABLE phpbb_reports (
|
||||
reported_post_text TEXT DEFAULT '' NOT NULL,
|
||||
reported_post_uid varchar(8) DEFAULT '' NOT NULL,
|
||||
reported_post_bitfield varchar(255) DEFAULT '' NOT NULL,
|
||||
reported_post_enable_magic_url INT2 DEFAULT '1' NOT NULL CHECK (reported_post_enable_magic_url >= 0),
|
||||
reported_post_enable_smilies INT2 DEFAULT '1' NOT NULL CHECK (reported_post_enable_smilies >= 0),
|
||||
reported_post_enable_bbcode INT2 DEFAULT '1' NOT NULL CHECK (reported_post_enable_bbcode >= 0),
|
||||
PRIMARY KEY (report_id)
|
||||
);
|
||||
|
||||
|
@@ -654,7 +654,10 @@ CREATE TABLE phpbb_reports (
|
||||
report_text mediumtext(16777215) NOT NULL DEFAULT '',
|
||||
reported_post_text mediumtext(16777215) NOT NULL DEFAULT '',
|
||||
reported_post_uid varchar(8) NOT NULL DEFAULT '',
|
||||
reported_post_bitfield varchar(255) NOT NULL DEFAULT ''
|
||||
reported_post_bitfield varchar(255) NOT NULL DEFAULT '',
|
||||
reported_post_enable_magic_url INTEGER UNSIGNED NOT NULL DEFAULT '1',
|
||||
reported_post_enable_smilies INTEGER UNSIGNED NOT NULL DEFAULT '1',
|
||||
reported_post_enable_bbcode INTEGER UNSIGNED NOT NULL DEFAULT '1'
|
||||
);
|
||||
|
||||
CREATE INDEX phpbb_reports_post_id ON phpbb_reports (post_id);
|
||||
|
Reference in New Issue
Block a user