From a694c17791eb0375bc9259397a68849a35145281 Mon Sep 17 00:00:00 2001 From: David M Date: Tue, 10 Jul 2007 17:46:47 +0000 Subject: [PATCH] #12777 git-svn-id: file:///svn/phpbb/trunk@7864 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/docs/CHANGELOG.html | 1 + phpBB/includes/acp/acp_php_info.php | 11 ++++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) 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);