aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/acp/acp_main.php
diff options
context:
space:
mode:
authorjaviexin <javiexin@gmail.com>2017-02-15 23:56:52 +0100
committerGitHub <noreply@github.com>2017-02-15 23:56:52 +0100
commit7f69580df3b6125941fc39d63f8498488f32231a (patch)
treef7c3816515cdbe98aee078f8ece97d79f77bd017 /phpBB/includes/acp/acp_main.php
parent7646280d518a4f637ec267fadb5e563f5b149512 (diff)
parentb567c6e2414d069ba54f7a924c952069aa115237 (diff)
downloadforums-7f69580df3b6125941fc39d63f8498488f32231a.tar
forums-7f69580df3b6125941fc39d63f8498488f32231a.tar.gz
forums-7f69580df3b6125941fc39d63f8498488f32231a.tar.bz2
forums-7f69580df3b6125941fc39d63f8498488f32231a.tar.xz
forums-7f69580df3b6125941fc39d63f8498488f32231a.zip
Merge branch '3.1.x' into ticket/15011
Diffstat (limited to 'phpBB/includes/acp/acp_main.php')
-rw-r--r--phpBB/includes/acp/acp_main.php18
1 files changed, 14 insertions, 4 deletions
diff --git a/phpBB/includes/acp/acp_main.php b/phpBB/includes/acp/acp_main.php
index 848cafeb67..6e7bd91a86 100644
--- a/phpBB/includes/acp/acp_main.php
+++ b/phpBB/includes/acp/acp_main.php
@@ -421,23 +421,33 @@ class acp_main
// 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,
- 'L_PHP_VERSION_OLD' => sprintf($user->lang['PHP_VERSION_OLD'], '<a href="https://www.phpbb.com/community/viewtopic.php?f=14&amp;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);
- $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)
{