Line 421 | Line 421 |
---|
// Version check $user->add_lang('install');
|
// Version check $user->add_lang('install');
|
if ($auth->acl_get('a_server') && version_compare(PHP_VERSION, '5.3.3', '<'))
| if ($auth->acl_get('a_server') && version_compare(PHP_VERSION, '5.4.0', '<'))
|
{ $template->assign_vars(array( 'S_PHP_VERSION_OLD' => true,
|
{ $template->assign_vars(array( 'S_PHP_VERSION_OLD' => true,
|
'L_PHP_VERSION_OLD' => sprintf($user->lang['PHP_VERSION_OLD'], '<a href="https://www.phpbb.com/community/viewtopic.php?f=14&t=2152375">', '</a>'),
| 'L_PHP_VERSION_OLD' => sprintf($user->lang['PHP_VERSION_OLD'], PHP_VERSION, '5.4.0', '<a href="https://www.phpbb.com/support/docs/en/3.2/ug/quickstart/requirements">', '</a>'),
|
)); }
|
)); }
|
| if ($auth->acl_get('a_board')) { /** @var \phpbb\version_helper $version_helper */
|
$version_helper = $phpbb_container->get('version_helper'); try { $recheck = $request->variable('versioncheck_force', false);
|
$version_helper = $phpbb_container->get('version_helper'); try { $recheck = $request->variable('versioncheck_force', false);
|
$updates_available = $version_helper->get_suggested_updates($recheck);
| $updates_available = $version_helper->get_update_on_branch($recheck); $upgrades_available = $version_helper->get_suggested_updates(); if (!empty($upgrades_available)) { $upgrades_available = array_pop($upgrades_available); }
|
|
|
$template->assign_var('S_VERSION_UP_TO_DATE', empty($updates_available));
| $template->assign_vars(array( 'S_VERSION_UP_TO_DATE' => empty($updates_available), 'S_VERSION_UPGRADEABLE' => !empty($upgrades_available), 'UPGRADE_INSTRUCTIONS' => !empty($upgrades_available) ? $user->lang('UPGRADE_INSTRUCTIONS', $upgrades_available['current'], $upgrades_available['announcement']) : false, ));
|
} catch (\RuntimeException $e) {
| } catch (\RuntimeException $e) {
|
Line 443 | Line 455 |
---|
'S_VERSIONCHECK_FAIL' => true, 'VERSIONCHECK_FAIL_REASON' => ($e->getMessage() !== $user->lang('VERSIONCHECK_FAIL')) ? $e->getMessage() : '', ));
|
'S_VERSIONCHECK_FAIL' => true, 'VERSIONCHECK_FAIL_REASON' => ($e->getMessage() !== $user->lang('VERSIONCHECK_FAIL')) ? $e->getMessage() : '', ));
|
| } } else { // We set this template var to true, to not display an outdated version notice. $template->assign_var('S_VERSION_UP_TO_DATE', true); }
// Incomplete update? if (phpbb_version_compare($config['version'], PHPBB_VERSION, '<')) { $template->assign_var('S_UPDATE_INCOMPLETE', true);
|
}
/**
| }
/**
|
Line 553 | Line 577 |
---|
'U_VERSIONCHECK' => append_sid("{$phpbb_admin_path}index.$phpEx", 'i=update&mode=version_check'), 'U_VERSIONCHECK_FORCE' => append_sid("{$phpbb_admin_path}index.$phpEx", 'versioncheck_force=1'),
|
'U_VERSIONCHECK' => append_sid("{$phpbb_admin_path}index.$phpEx", 'i=update&mode=version_check'), 'U_VERSIONCHECK_FORCE' => append_sid("{$phpbb_admin_path}index.$phpEx", 'versioncheck_force=1'),
|
| 'S_VERSIONCHECK' => ($auth->acl_get('a_board')) ? true : false,
|
'S_ACTION_OPTIONS' => ($auth->acl_get('a_board')) ? true : false, 'S_FOUNDER' => ($user->data['user_type'] == USER_FOUNDER) ? true : false, )
| 'S_ACTION_OPTIONS' => ($auth->acl_get('a_board')) ? true : false, 'S_FOUNDER' => ($user->data['user_type'] == USER_FOUNDER) ? true : false, )
|
Line 632 | Line 657 |
---|
{ $error = false; $search_type = $config['search_type'];
|
{ $error = false; $search_type = $config['search_type'];
|
$search = new $search_type($error, $phpbb_root_path, $phpEx, $auth, $config, $db, $user);
| $search = new $search_type($error, $phpbb_root_path, $phpEx, $auth, $config, $db, $user, $phpbb_dispatcher);
|
if (!$search->index_created()) {
| if (!$search->index_created()) {
|