diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html index ddc8ec9f17..2c0bcc6f37 100644 --- a/phpBB/docs/CHANGELOG.html +++ b/phpBB/docs/CHANGELOG.html @@ -204,6 +204,7 @@ p a {
  • [Fix] Place attachment filename in new line in posting editor (Bug #9726)
  • [Fix] Don't allow caching to occur in the update sequence (Bug #13207)
  • [Fix] Enforce the max password length for automatically generated password created by the password sender (Bug #13181)
  • +
  • [Fix] Handle phpinfo() when expose_php is false (Bug #12777)
  • diff --git a/phpBB/includes/acp/acp_php_info.php b/phpBB/includes/acp/acp_php_info.php index d18d64b076..3b4873bdc8 100644 --- a/phpBB/includes/acp/acp_php_info.php +++ b/phpBB/includes/acp/acp_php_info.php @@ -45,7 +45,16 @@ class acp_php_info } $output = $output[1][0]; - $output = preg_replace('#(.*?]*>]*>)(.*?)#s', '
    \2\1
    ', $output); + + // expose_php can make the image not exist + if (preg_match('#]*>]*>#', $output)) + { + $output = preg_replace('#(.*?]*>]*>)(.*?)#s', '
    \2\1
    ', $output); + } + else + { + $output = preg_replace('#(.*?)#s', '
    \1
    ', $output); + } $output = preg_replace('#]+>#i', '', $output); $output = preg_replace('#', ''), array('class="row1"', 'class="row2"', '', '', ''), $output);